@alfadocs/ui-kit-debug 1.108.0 → 1.110.0

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 (115) hide show
  1. package/dist/_chunks/{public-footer-3Jy1zHSs.js → public-footer-DGjLTtNK.js} +30 -30
  2. package/dist/_chunks/public-footer-DGjLTtNK.js.map +1 -0
  3. package/dist/_chunks/{reviews-panel-CtrwZOUS.js → reviews-panel-B03auSpQ.js} +210 -207
  4. package/dist/_chunks/reviews-panel-B03auSpQ.js.map +1 -0
  5. package/dist/_chunks/{signature-request-DtLph5Z4.js → signature-request-opW0fQ5P.js} +1032 -1016
  6. package/dist/_chunks/signature-request-opW0fQ5P.js.map +1 -0
  7. package/dist/_chunks/{signed-out-frame-Bs_LSPWe.js → signed-out-frame-CPow3aCZ.js} +2 -2
  8. package/dist/_chunks/{signed-out-frame-Bs_LSPWe.js.map → signed-out-frame-CPow3aCZ.js.map} +1 -1
  9. package/dist/agent-catalog.json +2 -2
  10. package/dist/agent-i18n/en.json +1 -1
  11. package/dist/components/public-footer/index.js +1 -1
  12. package/dist/components/reviews-panel/index.js +1 -1
  13. package/dist/components/reviews-panel/reviews-panel.d.ts +7 -0
  14. package/dist/components/reviews-panel/reviews-panel.d.ts.map +1 -1
  15. package/dist/i18n/locales/ar.d.ts +3 -0
  16. package/dist/i18n/locales/ar.d.ts.map +1 -1
  17. package/dist/i18n/locales/ar.js +3 -0
  18. package/dist/i18n/locales/ar.js.map +1 -1
  19. package/dist/i18n/locales/de.d.ts +3 -0
  20. package/dist/i18n/locales/de.d.ts.map +1 -1
  21. package/dist/i18n/locales/de.js +3 -0
  22. package/dist/i18n/locales/de.js.map +1 -1
  23. package/dist/i18n/locales/el.d.ts +3 -0
  24. package/dist/i18n/locales/el.d.ts.map +1 -1
  25. package/dist/i18n/locales/el.js +3 -0
  26. package/dist/i18n/locales/el.js.map +1 -1
  27. package/dist/i18n/locales/en.d.ts +3 -0
  28. package/dist/i18n/locales/en.d.ts.map +1 -1
  29. package/dist/i18n/locales/en.js +3 -0
  30. package/dist/i18n/locales/en.js.map +1 -1
  31. package/dist/i18n/locales/es.d.ts +3 -0
  32. package/dist/i18n/locales/es.d.ts.map +1 -1
  33. package/dist/i18n/locales/es.js +3 -0
  34. package/dist/i18n/locales/es.js.map +1 -1
  35. package/dist/i18n/locales/fr.d.ts +3 -0
  36. package/dist/i18n/locales/fr.d.ts.map +1 -1
  37. package/dist/i18n/locales/fr.js +3 -0
  38. package/dist/i18n/locales/fr.js.map +1 -1
  39. package/dist/i18n/locales/hi.d.ts +3 -0
  40. package/dist/i18n/locales/hi.d.ts.map +1 -1
  41. package/dist/i18n/locales/hi.js +3 -0
  42. package/dist/i18n/locales/hi.js.map +1 -1
  43. package/dist/i18n/locales/it.d.ts +3 -0
  44. package/dist/i18n/locales/it.d.ts.map +1 -1
  45. package/dist/i18n/locales/it.js +3 -0
  46. package/dist/i18n/locales/it.js.map +1 -1
  47. package/dist/i18n/locales/ja.d.ts +3 -0
  48. package/dist/i18n/locales/ja.d.ts.map +1 -1
  49. package/dist/i18n/locales/ja.js +3 -0
  50. package/dist/i18n/locales/ja.js.map +1 -1
  51. package/dist/i18n/locales/nl.d.ts +3 -0
  52. package/dist/i18n/locales/nl.d.ts.map +1 -1
  53. package/dist/i18n/locales/nl.js +3 -0
  54. package/dist/i18n/locales/nl.js.map +1 -1
  55. package/dist/i18n/locales/pl.d.ts +3 -0
  56. package/dist/i18n/locales/pl.d.ts.map +1 -1
  57. package/dist/i18n/locales/pl.js +3 -0
  58. package/dist/i18n/locales/pl.js.map +1 -1
  59. package/dist/i18n/locales/pt.d.ts +3 -0
  60. package/dist/i18n/locales/pt.d.ts.map +1 -1
  61. package/dist/i18n/locales/pt.js +3 -0
  62. package/dist/i18n/locales/pt.js.map +1 -1
  63. package/dist/i18n/locales/ro.d.ts +3 -0
  64. package/dist/i18n/locales/ro.d.ts.map +1 -1
  65. package/dist/i18n/locales/ro.js +3 -0
  66. package/dist/i18n/locales/ro.js.map +1 -1
  67. package/dist/i18n/locales/ru.d.ts +3 -0
  68. package/dist/i18n/locales/ru.d.ts.map +1 -1
  69. package/dist/i18n/locales/ru.js +3 -0
  70. package/dist/i18n/locales/ru.js.map +1 -1
  71. package/dist/i18n/locales/sq.d.ts +3 -0
  72. package/dist/i18n/locales/sq.d.ts.map +1 -1
  73. package/dist/i18n/locales/sq.js +3 -0
  74. package/dist/i18n/locales/sq.js.map +1 -1
  75. package/dist/i18n/locales/sv.d.ts +3 -0
  76. package/dist/i18n/locales/sv.d.ts.map +1 -1
  77. package/dist/i18n/locales/sv.js +3 -0
  78. package/dist/i18n/locales/sv.js.map +1 -1
  79. package/dist/i18n/locales/tr.d.ts +3 -0
  80. package/dist/i18n/locales/tr.d.ts.map +1 -1
  81. package/dist/i18n/locales/tr.js +3 -0
  82. package/dist/i18n/locales/tr.js.map +1 -1
  83. package/dist/i18n/locales/zh.d.ts +3 -0
  84. package/dist/i18n/locales/zh.d.ts.map +1 -1
  85. package/dist/i18n/locales/zh.js +3 -0
  86. package/dist/i18n/locales/zh.js.map +1 -1
  87. package/dist/index.js +4 -4
  88. package/dist/locales/ar.json +3 -0
  89. package/dist/locales/de.json +3 -0
  90. package/dist/locales/el.json +3 -0
  91. package/dist/locales/en.json +3 -0
  92. package/dist/locales/es.json +3 -0
  93. package/dist/locales/fr.json +3 -0
  94. package/dist/locales/hi.json +3 -0
  95. package/dist/locales/it.json +3 -0
  96. package/dist/locales/ja.json +3 -0
  97. package/dist/locales/nl.json +3 -0
  98. package/dist/locales/pl.json +3 -0
  99. package/dist/locales/pt.json +3 -0
  100. package/dist/locales/ro.json +3 -0
  101. package/dist/locales/ru.json +3 -0
  102. package/dist/locales/sq.json +3 -0
  103. package/dist/locales/sv.json +3 -0
  104. package/dist/locales/tr.json +3 -0
  105. package/dist/locales/zh.json +3 -0
  106. package/dist/patterns/signature-request/index.js +1 -1
  107. package/dist/patterns/signature-request/required-documents.d.ts +7 -3
  108. package/dist/patterns/signature-request/required-documents.d.ts.map +1 -1
  109. package/dist/patterns/signature-request/signature-request.d.ts +27 -21
  110. package/dist/patterns/signature-request/signature-request.d.ts.map +1 -1
  111. package/dist/patterns/signed-out-frame/index.js +1 -1
  112. package/package.json +1 -1
  113. package/dist/_chunks/public-footer-3Jy1zHSs.js.map +0 -1
  114. package/dist/_chunks/reviews-panel-CtrwZOUS.js.map +0 -1
  115. package/dist/_chunks/signature-request-DtLph5Z4.js.map +0 -1
@@ -1,56 +1,56 @@
1
- import { jsx as n, jsxs as u, Fragment as me } from "react/jsx-runtime";
2
- import { useState as _, useRef as ce, useEffect as Be, useId as B, forwardRef as Di, useLayoutEffect as Wt } from "react";
3
- import { useTranslation as Mn } from "react-i18next";
4
- import { D as C } from "./dialog-C7RWaH08.js";
5
- import { Q as Pi } from "./qr-code-DHEma21c.js";
6
- import { S as Li } from "./spinner-CoflYlEx.js";
7
- import { S as qe } from "./skeleton-tTWJpvAq.js";
1
+ import { jsx as n, jsxs as u, Fragment as ge } from "react/jsx-runtime";
2
+ import { useState as _, useRef as oe, useEffect as je, useId as B, forwardRef as Mi, useLayoutEffect as Qt } from "react";
3
+ import { useTranslation as Fn } from "react-i18next";
4
+ import { D as q } from "./dialog-C7RWaH08.js";
5
+ import { Q as $i } from "./qr-code-DHEma21c.js";
6
+ import { S as zi } from "./spinner-CoflYlEx.js";
7
+ import { S as Ie } from "./skeleton-tTWJpvAq.js";
8
8
  import { B as L } from "./button-DohK_Ak_.js";
9
- import { I as vn } from "./icon-button-S8_weU3g.js";
10
- import { s as _i, S as Ue } from "./select-BBDRYxJl.js";
11
- import { S as ga } from "./switch-DO6uC4HJ.js";
12
- import { A as U } from "./alert-C4WKViaS.js";
13
- import { S as pa } from "./separator-Bdc9bqoJ.js";
14
- import { A as Zn } from "./avatar-Dp5apm1d.js";
15
- import { L as Mi } from "./link-DtCfnLnF.js";
16
- import { L as at } from "./list-CNnn7DOD.js";
17
- import { a as Ea, T as Aa } from "./tooltip-uEBdD1-5.js";
18
- import { a as Da } from "./whatsapp-button-DV9JFmtq.js";
19
- import { c as rt } from "./createLucideIcon-DhHxpK9K.js";
20
- import { M as Pa } from "./mail-BqXVF2zH.js";
21
- import { M as $i } from "./message-square-Bye4ATvx.js";
22
- import { D as fn } from "./dropdown-menu-CqxBthww.js";
23
- import { S as zi } from "./signature-status-chip-pIoQjvH8.js";
24
- import { C as Hi } from "./chevron-down-DWE7GSq9.js";
25
- import { E as Fi } from "./eye-BjhN2nYf.js";
26
- import { D as fa } from "./download-CfYKJO_j.js";
27
- import { S as Bi } from "./share-2-B49jcW2I.js";
28
- import { T as va } from "./trash-2-uumy3fy1.js";
29
- import { U as Xt } from "./user-plus-BtcOLgNU.js";
30
- import { T as Ui } from "./triangle-alert-CBnO6nq_.js";
31
- import { C as Wi } from "./circle-check-BN6rz4NV.js";
32
- import { P as ba } from "./pen-line-D0De5zdl.js";
33
- import { S as ji } from "./send-C5kDJ-Mz.js";
34
- import { P as et } from "./plus-DzMQ_c6b.js";
35
- import { X as Ra } from "./x-B5YnXwCz.js";
9
+ import { I as xn } from "./icon-button-S8_weU3g.js";
10
+ import { s as Fi, S as Ue } from "./select-BBDRYxJl.js";
11
+ import { S as ba } from "./switch-DO6uC4HJ.js";
12
+ import { A as j } from "./alert-C4WKViaS.js";
13
+ import { S as Ra } from "./separator-Bdc9bqoJ.js";
14
+ import { A as st } from "./avatar-Dp5apm1d.js";
15
+ import { L as Hi } from "./link-DtCfnLnF.js";
16
+ import { L as ot } from "./list-CNnn7DOD.js";
17
+ import { a as La, T as _a } from "./tooltip-uEBdD1-5.js";
18
+ import { a as Ma } from "./whatsapp-button-DV9JFmtq.js";
19
+ import { c as dt } from "./createLucideIcon-DhHxpK9K.js";
20
+ import { M as $a } from "./mail-BqXVF2zH.js";
21
+ import { M as Bi } from "./message-square-Bye4ATvx.js";
22
+ import { D as Nn } from "./dropdown-menu-CqxBthww.js";
23
+ import { S as ji } from "./signature-status-chip-pIoQjvH8.js";
24
+ import { C as Ui } from "./chevron-down-DWE7GSq9.js";
25
+ import { E as Wi } from "./eye-BjhN2nYf.js";
26
+ import { D as Na } from "./download-CfYKJO_j.js";
27
+ import { S as Gi } from "./share-2-B49jcW2I.js";
28
+ import { T as xa } from "./trash-2-uumy3fy1.js";
29
+ import { U as es } from "./user-plus-BtcOLgNU.js";
30
+ import { T as Vi } from "./triangle-alert-CBnO6nq_.js";
31
+ import { C as Qi } from "./circle-check-BN6rz4NV.js";
32
+ import { P as qa } from "./pen-line-D0De5zdl.js";
33
+ import { S as Ki } from "./send-C5kDJ-Mz.js";
34
+ import { P as at } from "./plus-DzMQ_c6b.js";
35
+ import { X as Ca } from "./x-B5YnXwCz.js";
36
36
  /**
37
37
  * @license lucide-react v1.22.0 - ISC
38
38
  *
39
39
  * This source code is licensed under the ISC license.
40
40
  * See the LICENSE file in the root directory of this source tree.
41
41
  */
42
- const Gi = [
42
+ const Xi = [
43
43
  ["path", { d: "M9 17H7A5 5 0 0 1 7 7h2", key: "8i5ue5" }],
44
44
  ["path", { d: "M15 7h2a5 5 0 1 1 0 10h-2", key: "1b9ql8" }],
45
45
  ["line", { x1: "8", x2: "16", y1: "12", y2: "12", key: "1jonct" }]
46
- ], Vi = rt("link-2", Gi);
46
+ ], Yi = dt("link-2", Xi);
47
47
  /**
48
48
  * @license lucide-react v1.22.0 - ISC
49
49
  *
50
50
  * This source code is licensed under the ISC license.
51
51
  * See the LICENSE file in the root directory of this source tree.
52
52
  */
53
- const Qi = [
53
+ const Ji = [
54
54
  ["rect", { width: "5", height: "5", x: "3", y: "3", rx: "1", key: "1tu5fj" }],
55
55
  ["rect", { width: "5", height: "5", x: "16", y: "3", rx: "1", key: "1v8r4q" }],
56
56
  ["rect", { width: "5", height: "5", x: "3", y: "16", rx: "1", key: "1x03jg" }],
@@ -63,14 +63,14 @@ const Qi = [
63
63
  ["path", { d: "M16 12h1", key: "1slzba" }],
64
64
  ["path", { d: "M21 12v.01", key: "1lwtk9" }],
65
65
  ["path", { d: "M12 21v-1", key: "1880an" }]
66
- ], Ki = rt("qr-code", Qi);
66
+ ], Zi = dt("qr-code", Ji);
67
67
  /**
68
68
  * @license lucide-react v1.22.0 - ISC
69
69
  *
70
70
  * This source code is licensed under the ISC license.
71
71
  * See the LICENSE file in the root directory of this source tree.
72
72
  */
73
- const Xi = [
73
+ const er = [
74
74
  ["circle", { cx: "8", cy: "21", r: "1", key: "jimo8o" }],
75
75
  ["circle", { cx: "19", cy: "21", r: "1", key: "13723u" }],
76
76
  [
@@ -80,170 +80,170 @@ const Xi = [
80
80
  key: "9zh506"
81
81
  }
82
82
  ]
83
- ], Yi = rt("shopping-cart", Xi);
83
+ ], nr = dt("shopping-cart", er);
84
84
  /**
85
85
  * @license lucide-react v1.22.0 - ISC
86
86
  *
87
87
  * This source code is licensed under the ISC license.
88
88
  * See the LICENSE file in the root directory of this source tree.
89
89
  */
90
- const Ji = [
90
+ const tr = [
91
91
  ["rect", { width: "16", height: "20", x: "4", y: "2", rx: "2", ry: "2", key: "76otgf" }],
92
92
  ["line", { x1: "12", x2: "12.01", y1: "18", y2: "18", key: "1dp563" }]
93
- ], Zi = rt("tablet", Ji), it = [
93
+ ], sr = dt("tablet", tr), ct = [
94
94
  "sms",
95
95
  "email",
96
96
  "on-device"
97
- ], er = [
97
+ ], ar = [
98
98
  "sms",
99
99
  "email",
100
100
  "whatsapp",
101
101
  "on-device"
102
102
  ];
103
- function Yt() {
104
- const { t: i } = Mn("ui");
103
+ function ns() {
104
+ const { t: i } = Fn("ui");
105
105
  return {
106
106
  sms: {
107
107
  label: i("signatureRequest.viaSms"),
108
- icon: /* @__PURE__ */ n($i, { className: "ds:size-4", "aria-hidden": !0 })
108
+ icon: /* @__PURE__ */ n(Bi, { className: "ds:size-4", "aria-hidden": !0 })
109
109
  },
110
110
  email: {
111
111
  label: i("signatureRequest.viaEmail"),
112
- icon: /* @__PURE__ */ n(Pa, { className: "ds:size-4", "aria-hidden": !0 })
112
+ icon: /* @__PURE__ */ n($a, { className: "ds:size-4", "aria-hidden": !0 })
113
113
  },
114
114
  whatsapp: {
115
115
  label: i("signatureRequest.viaWhatsapp"),
116
- icon: /* @__PURE__ */ n(Da, { className: "ds:size-4", "aria-hidden": !0 })
116
+ icon: /* @__PURE__ */ n(Ma, { className: "ds:size-4", "aria-hidden": !0 })
117
117
  },
118
118
  "on-device": {
119
119
  label: i("signatureRequest.onThisDevice"),
120
- icon: /* @__PURE__ */ n(Zi, { className: "ds:size-4", "aria-hidden": !0 })
120
+ icon: /* @__PURE__ */ n(sr, { className: "ds:size-4", "aria-hidden": !0 })
121
121
  },
122
122
  qr: {
123
123
  label: i("signatureRequest.viaQr"),
124
- icon: /* @__PURE__ */ n(Ki, { className: "ds:size-4", "aria-hidden": !0 })
124
+ icon: /* @__PURE__ */ n(Zi, { className: "ds:size-4", "aria-hidden": !0 })
125
125
  }
126
126
  };
127
127
  }
128
- function La({
128
+ function za({
129
129
  loading: i,
130
130
  loadingText: o,
131
131
  loadedText: m,
132
132
  message: l
133
133
  }) {
134
- const [p, I] = _(""), k = ce(!1);
135
- return Be(() => {
136
- i ? I(o) : k.current && I(m), k.current = i;
134
+ const [p, w] = _(""), k = oe(!1);
135
+ return je(() => {
136
+ i ? w(o) : k.current && w(m), k.current = i;
137
137
  }, [i, o, m]), /* @__PURE__ */ n("span", { role: "status", className: "ds:sr-only", children: l !== void 0 && !i ? l : p });
138
138
  }
139
- const ae = "ds:grid ds:grid-cols-[var(--spacing-xl)_minmax(0,1fr)_var(--min-target-size)] ds:@[512px]/person:grid-cols-[var(--spacing-xl)_minmax(0,1fr)_max-content_var(--min-target-size)] ds:items-center ds:gap-x-[var(--spacing-sm)] ds:gap-y-[var(--spacing-sm)]", nt = "ds:col-start-1 ds:row-start-1 ds:flex ds:items-center ds:justify-center", Na = "ds:col-start-2 ds:row-start-1 ds:min-w-0", jt = "ds:col-[2/-2] ds:row-start-1 ds:min-w-0", tt = "ds:col-[-3/-2] ds:row-start-2 ds:min-w-0 ds:@[512px]/person:row-start-1", xa = "ds:col-[-2/-1] ds:row-start-1 ds:flex ds:items-center ds:justify-center", F = "ds:col-[2/-2] ds:min-w-0 ds:text-start", _n = "ds:col-[1/-2] ds:row-start-1 ds:flex ds:flex-wrap ds:items-center ds:justify-between ds:gap-[var(--spacing-sm)]", nr = "ds:flex ds:flex-col ds:gap-[var(--spacing-md)]", pn = "ds:@container/person";
140
- function _a({ meta: i }) {
139
+ const se = "ds:grid ds:grid-cols-[var(--spacing-xl)_minmax(0,1fr)_var(--min-target-size)] ds:@[512px]/person:grid-cols-[var(--spacing-xl)_minmax(0,1fr)_max-content_var(--min-target-size)] ds:items-center ds:gap-x-[var(--spacing-sm)] ds:gap-y-[var(--spacing-sm)]", it = "ds:col-start-1 ds:row-start-1 ds:flex ds:items-center ds:justify-center", Sa = "ds:col-start-2 ds:row-start-1 ds:min-w-0", Kt = "ds:col-[2/-2] ds:row-start-1 ds:min-w-0", rt = "ds:col-[-3/-2] ds:row-start-2 ds:min-w-0 ds:@[512px]/person:row-start-1", Ia = "ds:col-[-2/-1] ds:row-start-1 ds:flex ds:items-center ds:justify-center", H = "ds:col-[2/-2] ds:min-w-0 ds:text-start", zn = "ds:col-[1/-2] ds:row-start-1 ds:flex ds:flex-wrap ds:items-center ds:justify-between ds:gap-[var(--spacing-sm)]", ir = "ds:flex ds:flex-col ds:gap-[var(--spacing-md)]", Rn = "ds:@container/person";
140
+ function Fa({ meta: i }) {
141
141
  return /* @__PURE__ */ n(
142
142
  "span",
143
143
  {
144
144
  "aria-hidden": "true",
145
145
  "data-channel-sizer": "",
146
146
  className: "ds:invisible ds:block ds:h-0 ds:overflow-hidden",
147
- children: Object.entries(i).map(([o, { label: m, icon: l }]) => /* @__PURE__ */ n("span", { className: "ds:flex ds:w-max", children: /* @__PURE__ */ u("span", { className: _i({ size: "md" }), children: [
147
+ children: Object.entries(i).map(([o, { label: m, icon: l }]) => /* @__PURE__ */ n("span", { className: "ds:flex ds:w-max", children: /* @__PURE__ */ u("span", { className: Fi({ size: "md" }), children: [
148
148
  /* @__PURE__ */ u("span", { className: "ds:flex ds:items-center ds:gap-[var(--spacing-sm)]", children: [
149
149
  /* @__PURE__ */ n("span", { className: "ds:inline-flex ds:shrink-0", children: l }),
150
150
  /* @__PURE__ */ n("span", { className: "ds:whitespace-nowrap", children: m })
151
151
  ] }),
152
- /* @__PURE__ */ n(Hi, { className: "ds:size-4 ds:shrink-0" })
152
+ /* @__PURE__ */ n(Ui, { className: "ds:size-4 ds:shrink-0" })
153
153
  ] }) }, o))
154
154
  }
155
155
  );
156
156
  }
157
- const Ca = [
157
+ const wa = [
158
158
  "link",
159
159
  "email",
160
160
  "whatsapp"
161
- ], tr = [0, 1], sr = "ds:flex ds:flex-col ds:@[512px]/person:grid ds:@[512px]/person:grid-cols-[max-content_minmax(0,1fr)_max-content] ds:@[512px]/person:gap-x-[var(--spacing-md)]", qa = "ds:flex ds:flex-col ds:@[512px]/person:col-span-full ds:@[512px]/person:grid ds:@[512px]/person:grid-cols-subgrid", Gt = "ds:grid ds:grid-cols-[minmax(0,1fr)_max-content] ds:items-center ds:gap-x-[var(--spacing-sm)] ds:gap-y-[var(--spacing-xs)] ds:py-[var(--spacing-xs)] ds:@[512px]/person:col-span-full ds:@[512px]/person:grid-cols-subgrid ds:@[512px]/person:gap-x-[var(--spacing-md)]", Sa = "ds:col-start-1 ds:row-start-1 ds:min-w-0 ds:text-start ds:@[512px]/person:col-start-1 ds:@[512px]/person:whitespace-nowrap", wa = "ds:col-span-full ds:row-start-2 ds:min-w-0 ds:text-start ds:@[512px]/person:col-span-1 ds:@[512px]/person:col-start-2 ds:@[512px]/person:row-start-1", Ia = "ds:col-start-2 ds:row-start-1 ds:flex ds:justify-end ds:@[512px]/person:col-start-3";
162
- function Ma(i) {
161
+ ], rr = [0, 1], lr = "ds:flex ds:flex-col ds:@[512px]/person:grid ds:@[512px]/person:grid-cols-[max-content_minmax(0,1fr)_max-content] ds:@[512px]/person:gap-x-[var(--spacing-md)]", ya = "ds:flex ds:flex-col ds:@[512px]/person:col-span-full ds:@[512px]/person:grid ds:@[512px]/person:grid-cols-subgrid", Xt = "ds:grid ds:grid-cols-[minmax(0,1fr)_max-content] ds:items-center ds:gap-x-[var(--spacing-sm)] ds:gap-y-[var(--spacing-xs)] ds:py-[var(--spacing-xs)] ds:@[512px]/person:col-span-full ds:@[512px]/person:grid-cols-subgrid ds:@[512px]/person:gap-x-[var(--spacing-md)]", ka = "ds:col-start-1 ds:row-start-1 ds:min-w-0 ds:text-start ds:@[512px]/person:col-start-1 ds:@[512px]/person:whitespace-nowrap", Oa = "ds:col-span-full ds:row-start-2 ds:min-w-0 ds:text-start ds:@[512px]/person:col-span-1 ds:@[512px]/person:col-start-2 ds:@[512px]/person:row-start-1", Ta = "ds:col-start-2 ds:row-start-1 ds:flex ds:justify-end ds:@[512px]/person:col-start-3";
162
+ function Ha(i) {
163
163
  const o = (i instanceof Date ? i : new Date(i)).getTime();
164
164
  return Number.isNaN(o) ? null : o;
165
165
  }
166
- function ar(i) {
167
- return i.map((o, m) => ({ record: o, index: m, ms: Ma(o.createdAt) })).sort((o, m) => o.ms === m.ms ? o.index - m.index : o.ms === null ? 1 : m.ms === null ? -1 : m.ms - o.ms).map(({ record: o }) => o);
166
+ function or(i) {
167
+ return i.map((o, m) => ({ record: o, index: m, ms: Ha(o.createdAt) })).sort((o, m) => o.ms === m.ms ? o.index - m.index : o.ms === null ? 1 : m.ms === null ? -1 : m.ms - o.ms).map(({ record: o }) => o);
168
168
  }
169
- function ir({
169
+ function cr({
170
170
  signatures: i,
171
171
  loading: o = !1,
172
172
  showLegalLevel: m = !0,
173
173
  onView: l,
174
174
  onDownload: p,
175
- onShare: I,
176
- shareTargets: k = Ca,
177
- onDelete: j
175
+ onShare: w,
176
+ shareTargets: k = wa,
177
+ onDelete: W
178
178
  }) {
179
- const { t: R, i18n: Z } = Mn("ui"), $ = Yt(), Se = B(), Ae = {
180
- link: { label: R("signatureRequest.shareLink"), icon: /* @__PURE__ */ n(Vi, {}) },
181
- email: { label: R("signatureRequest.viaEmail"), icon: /* @__PURE__ */ n(Pa, {}) },
179
+ const { t: R, i18n: Z } = Fn("ui"), $ = ns(), pe = B(), Pe = {
180
+ link: { label: R("signatureRequest.shareLink"), icon: /* @__PURE__ */ n(Yi, {}) },
181
+ email: { label: R("signatureRequest.viaEmail"), icon: /* @__PURE__ */ n($a, {}) },
182
182
  whatsapp: {
183
183
  label: R("signatureRequest.viaWhatsapp"),
184
- icon: /* @__PURE__ */ n(Da, {})
184
+ icon: /* @__PURE__ */ n(Ma, {})
185
185
  }
186
- }, Ye = Z.language || "en", De = Ye === "en" ? "en-GB" : Ye, y = new Intl.DateTimeFormat(De, {
186
+ }, nn = Z.language || "en", Le = nn === "en" ? "en-GB" : nn, y = new Intl.DateTimeFormat(Le, {
187
187
  weekday: "short"
188
- }), ie = new Intl.DateTimeFormat(De, {
188
+ }), ae = new Intl.DateTimeFormat(Le, {
189
189
  day: "2-digit",
190
190
  month: "2-digit",
191
191
  year: "numeric"
192
- }), Je = new Intl.DateTimeFormat(De, {
192
+ }), tn = new Intl.DateTimeFormat(Le, {
193
193
  hour: "2-digit",
194
194
  minute: "2-digit"
195
195
  }), We = (M) => {
196
196
  const b = y.format(M);
197
197
  return R("signatureRequest.signedAt", {
198
- weekday: b.charAt(0).toLocaleUpperCase(De) + b.slice(1),
199
- date: ie.format(M),
200
- time: Je.format(M),
198
+ weekday: b.charAt(0).toLocaleUpperCase(Le) + b.slice(1),
199
+ date: ae.format(M),
200
+ time: tn.format(M),
201
201
  interpolation: { escapeValue: !1 }
202
202
  });
203
- }, we = ce(null), de = ce(null), je = ce(null), [Ie, Pe] = _();
204
- Be(() => {
205
- const M = je.current;
203
+ }, we = oe(null), ce = oe(null), Ge = oe(null), [ye, _e] = _();
204
+ je(() => {
205
+ const M = Ge.current;
206
206
  if (!M || o) return;
207
207
  const b = new Set((i ?? []).map((z) => z.id));
208
208
  if (b.has(M.id)) return;
209
- je.current = null, Pe(R("signatureRequest.signatureDeleted"));
209
+ Ge.current = null, _e(R("signatureRequest.signatureDeleted"));
210
210
  const E = M.order.indexOf(M.id), ee = M.order.slice(E + 1).find((z) => b.has(z)) ?? M.order.slice(0, E).reverse().find((z) => b.has(z));
211
211
  window.setTimeout(() => {
212
- var ge, ke, pe;
212
+ var de, Oe, fe;
213
213
  const z = document.activeElement;
214
214
  if (!(!z || z === document.body || !z.isConnected || z.matches('[role="dialog"], [role="alertdialog"]'))) return;
215
215
  if (ee === void 0) {
216
- (ge = de.current) == null || ge.focus();
216
+ (de = ce.current) == null || de.focus();
217
217
  return;
218
218
  }
219
- const W = Array.from(
220
- ((ke = we.current) == null ? void 0 : ke.querySelectorAll(
219
+ const U = Array.from(
220
+ ((Oe = we.current) == null ? void 0 : Oe.querySelectorAll(
221
221
  "[data-signature-id]"
222
222
  )) ?? []
223
- ).find((re) => re.dataset.signatureId === ee);
224
- (pe = W == null ? void 0 : W.querySelector('[role="group"] button')) == null || pe.focus();
223
+ ).find((ie) => ie.dataset.signatureId === ee);
224
+ (fe = U == null ? void 0 : U.querySelector('[role="group"] button')) == null || fe.focus();
225
225
  }, 0);
226
226
  }, [i, o, R]);
227
- const O = i ? ar(i) : [];
228
- let ye;
227
+ const O = i ? or(i) : [];
228
+ let ke;
229
229
  if (o)
230
- ye = /* @__PURE__ */ n(
230
+ ke = /* @__PURE__ */ n(
231
231
  "div",
232
232
  {
233
233
  "aria-busy": "true",
234
234
  className: "ds:flex ds:flex-col ds:gap-[var(--spacing-sm)]",
235
- children: tr.map((M) => /* @__PURE__ */ u(
235
+ children: rr.map((M) => /* @__PURE__ */ u(
236
236
  "div",
237
237
  {
238
238
  className: "ds:flex ds:items-center ds:gap-[var(--spacing-sm)]",
239
239
  children: [
240
240
  /* @__PURE__ */ u("div", { className: "ds:flex ds:min-w-0 ds:flex-1 ds:flex-col ds:gap-[var(--spacing-xs)]", children: [
241
- /* @__PURE__ */ n(qe, { size: "md", width: "40%" }),
242
- /* @__PURE__ */ n(qe, { size: "sm", width: "70%" })
241
+ /* @__PURE__ */ n(Ie, { size: "md", width: "40%" }),
242
+ /* @__PURE__ */ n(Ie, { size: "sm", width: "70%" })
243
243
  ] }),
244
- /* @__PURE__ */ n(qe, { variant: "circular", size: "sm" }),
245
- /* @__PURE__ */ n(qe, { variant: "circular", size: "sm" }),
246
- /* @__PURE__ */ n(qe, { variant: "circular", size: "sm" })
244
+ /* @__PURE__ */ n(Ie, { variant: "circular", size: "sm" }),
245
+ /* @__PURE__ */ n(Ie, { variant: "circular", size: "sm" }),
246
+ /* @__PURE__ */ n(Ie, { variant: "circular", size: "sm" })
247
247
  ]
248
248
  },
249
249
  M
@@ -251,10 +251,10 @@ function ir({
251
251
  }
252
252
  );
253
253
  else if (O.length === 0)
254
- ye = /* @__PURE__ */ n(
254
+ ke = /* @__PURE__ */ n(
255
255
  "p",
256
256
  {
257
- ref: de,
257
+ ref: ce,
258
258
  tabIndex: -1,
259
259
  "data-note": "no-signed-versions",
260
260
  className: "type-body-sm ds:text-[color:var(--muted-foreground)] ds:outline-none",
@@ -263,32 +263,32 @@ function ir({
263
263
  );
264
264
  else {
265
265
  const M = "type-label ds:text-[color:var(--muted-foreground)] ds:pb-[var(--spacing-xs)]";
266
- ye = // The chip's tooltip and the icon-button tooltips need a provider; the
266
+ ke = // The chip's tooltip and the icon-button tooltips need a provider; the
267
267
  // section brings its own so a host without one does not crash.
268
- /* @__PURE__ */ n(Ea, { children: /* @__PURE__ */ u(
268
+ /* @__PURE__ */ n(La, { children: /* @__PURE__ */ u(
269
269
  "div",
270
270
  {
271
271
  ref: we,
272
272
  role: "table",
273
- "aria-labelledby": Se,
274
- className: sr,
273
+ "aria-labelledby": pe,
274
+ className: lr,
275
275
  children: [
276
276
  /* @__PURE__ */ n(
277
277
  "div",
278
278
  {
279
279
  role: "rowgroup",
280
- className: `${qa} ds:sr-only ds:@[512px]/person:not-sr-only`,
280
+ className: `${ya} ds:sr-only ds:@[512px]/person:not-sr-only`,
281
281
  children: /* @__PURE__ */ u(
282
282
  "div",
283
283
  {
284
284
  role: "row",
285
- className: `${Gt} ds:border-b ds:border-[color:var(--border)]`,
285
+ className: `${Xt} ds:border-b ds:border-[color:var(--border)]`,
286
286
  children: [
287
287
  /* @__PURE__ */ n(
288
288
  "span",
289
289
  {
290
290
  role: "columnheader",
291
- className: `${Sa} ${M}`,
291
+ className: `${ka} ${M}`,
292
292
  children: R("signatureRequest.columnDate")
293
293
  }
294
294
  ),
@@ -296,7 +296,7 @@ function ir({
296
296
  "span",
297
297
  {
298
298
  role: "columnheader",
299
- className: `${wa} ${M}`,
299
+ className: `${Oa} ${M}`,
300
300
  children: R("signatureRequest.columnSignatureType")
301
301
  }
302
302
  ),
@@ -304,7 +304,7 @@ function ir({
304
304
  "span",
305
305
  {
306
306
  role: "columnheader",
307
- className: `${Ia} ${M}`,
307
+ className: `${Ta} ${M}`,
308
308
  children: R("signatureRequest.columnActions")
309
309
  }
310
310
  )
@@ -313,19 +313,19 @@ function ir({
313
313
  )
314
314
  }
315
315
  ),
316
- /* @__PURE__ */ n("div", { role: "rowgroup", className: qa, children: O.map((b, E) => {
317
- const ee = Ma(b.createdAt), z = ee === null ? String(b.createdAt) : We(ee), N = ee === null ? void 0 : new Date(ee).toISOString(), W = $[b.channel], ge = b.shareTargets ?? k, ke = I ? Ca.filter(
318
- (re) => ge.includes(re)
319
- ) : [], pe = l !== void 0 || p !== void 0 || ke.length > 0 || j !== void 0;
316
+ /* @__PURE__ */ n("div", { role: "rowgroup", className: ya, children: O.map((b, E) => {
317
+ const ee = Ha(b.createdAt), z = ee === null ? String(b.createdAt) : We(ee), x = ee === null ? void 0 : new Date(ee).toISOString(), U = $[b.channel], de = b.shareTargets ?? k, Oe = w ? wa.filter(
318
+ (ie) => de.includes(ie)
319
+ ) : [], fe = l !== void 0 || p !== void 0 || Oe.length > 0 || W !== void 0;
320
320
  return /* @__PURE__ */ u(
321
321
  "div",
322
322
  {
323
323
  role: "row",
324
324
  "data-signature-id": b.id,
325
- className: E === 0 ? Gt : `${Gt} ds:border-t ds:border-[color:var(--border)]`,
325
+ className: E === 0 ? Xt : `${Xt} ds:border-t ds:border-[color:var(--border)]`,
326
326
  children: [
327
- /* @__PURE__ */ n("div", { role: "cell", className: `${Sa} type-body`, children: /* @__PURE__ */ n("time", { dateTime: N, children: z }) }),
328
- /* @__PURE__ */ n("div", { role: "cell", className: wa, children: /* @__PURE__ */ u("span", { className: "type-body-sm ds:flex ds:flex-wrap ds:items-center ds:gap-x-[var(--spacing-md)] ds:gap-y-[var(--spacing-xs)] ds:text-[color:var(--muted-foreground)]", children: [
327
+ /* @__PURE__ */ n("div", { role: "cell", className: `${ka} type-body`, children: /* @__PURE__ */ n("time", { dateTime: x, children: z }) }),
328
+ /* @__PURE__ */ n("div", { role: "cell", className: Oa, children: /* @__PURE__ */ u("span", { className: "type-body-sm ds:flex ds:flex-wrap ds:items-center ds:gap-x-[var(--spacing-md)] ds:gap-y-[var(--spacing-xs)] ds:text-[color:var(--muted-foreground)]", children: [
329
329
  m && b.legalLevel ? /* @__PURE__ */ n("span", { children: b.legalLevel === "advanced" ? R("signatureRequest.legalLevelAdvanced") : R("signatureRequest.legalLevelSimple") }) : null,
330
330
  /* @__PURE__ */ u("span", { className: "ds:inline-flex ds:items-center ds:gap-[var(--spacing-xs)]", children: [
331
331
  /* @__PURE__ */ n(
@@ -333,13 +333,13 @@ function ir({
333
333
  {
334
334
  "aria-hidden": "true",
335
335
  className: "ds:text-[var(--accent)]",
336
- children: W.icon
336
+ children: U.icon
337
337
  }
338
338
  ),
339
- W.label
339
+ U.label
340
340
  ] }),
341
341
  /* @__PURE__ */ n(
342
- zi,
342
+ ji,
343
343
  {
344
344
  size: "sm",
345
345
  operator: b.operator,
@@ -350,7 +350,7 @@ function ir({
350
350
  }
351
351
  )
352
352
  ] }) }),
353
- /* @__PURE__ */ n("div", { role: "cell", className: Ia, children: pe ? /* @__PURE__ */ u(
353
+ /* @__PURE__ */ n("div", { role: "cell", className: Ta, children: fe ? /* @__PURE__ */ u(
354
354
  "span",
355
355
  {
356
356
  role: "group",
@@ -361,32 +361,32 @@ function ir({
361
361
  className: "ds:flex ds:items-center ds:gap-[var(--spacing-xs)]",
362
362
  children: [
363
363
  l ? /* @__PURE__ */ n(
364
- vn,
364
+ xn,
365
365
  {
366
366
  intent: "ghost",
367
367
  size: "sm",
368
- icon: /* @__PURE__ */ n(Fi, {}),
368
+ icon: /* @__PURE__ */ n(Wi, {}),
369
369
  "aria-label": R("signatureRequest.viewSignature"),
370
370
  tooltip: R("signatureRequest.viewSignature"),
371
371
  onClick: () => l(b.id)
372
372
  }
373
373
  ) : null,
374
374
  p && b.hasAnonymisedVersion ? /* @__PURE__ */ u(
375
- ya,
375
+ Ea,
376
376
  {
377
377
  id: `signature-download-${b.id}`,
378
378
  label: R("signatureRequest.downloadSignature"),
379
- icon: /* @__PURE__ */ n(fa, {}),
379
+ icon: /* @__PURE__ */ n(Na, {}),
380
380
  children: [
381
381
  /* @__PURE__ */ n(
382
- fn.Item,
382
+ Nn.Item,
383
383
  {
384
384
  onSelect: () => p(b.id, "full"),
385
385
  children: R("signatureRequest.downloadFull")
386
386
  }
387
387
  ),
388
388
  /* @__PURE__ */ n(
389
- fn.Item,
389
+ Nn.Item,
390
390
  {
391
391
  onSelect: () => p(b.id, "anonymised"),
392
392
  children: R("signatureRequest.downloadAnonymised")
@@ -398,45 +398,45 @@ function ir({
398
398
  // One file only: a menu with a single entry would
399
399
  // be an extra click for nothing.
400
400
  /* @__PURE__ */ n(
401
- vn,
401
+ xn,
402
402
  {
403
403
  intent: "ghost",
404
404
  size: "sm",
405
- icon: /* @__PURE__ */ n(fa, {}),
405
+ icon: /* @__PURE__ */ n(Na, {}),
406
406
  "aria-label": R("signatureRequest.downloadSignature"),
407
407
  tooltip: R("signatureRequest.downloadSignature"),
408
408
  onClick: () => p(b.id, "full")
409
409
  }
410
410
  )
411
411
  ) : null,
412
- I && ke.length > 0 ? /* @__PURE__ */ n(
413
- ya,
412
+ w && Oe.length > 0 ? /* @__PURE__ */ n(
413
+ Ea,
414
414
  {
415
415
  id: `signature-share-${b.id}`,
416
416
  label: R("signatureRequest.shareSignature"),
417
- icon: /* @__PURE__ */ n(Bi, {}),
418
- children: ke.map((re) => /* @__PURE__ */ n(
419
- fn.Item,
417
+ icon: /* @__PURE__ */ n(Gi, {}),
418
+ children: Oe.map((ie) => /* @__PURE__ */ n(
419
+ Nn.Item,
420
420
  {
421
- startIcon: Ae[re].icon,
422
- onSelect: () => I(b.id, re),
423
- children: Ae[re].label
421
+ startIcon: Pe[ie].icon,
422
+ onSelect: () => w(b.id, ie),
423
+ children: Pe[ie].label
424
424
  },
425
- re
425
+ ie
426
426
  ))
427
427
  }
428
428
  ) : null,
429
- j ? /* @__PURE__ */ n(
430
- rr,
429
+ W ? /* @__PURE__ */ n(
430
+ dr,
431
431
  {
432
432
  id: `signature-delete-${b.id}`,
433
433
  when: z,
434
- dateTime: N,
434
+ dateTime: x,
435
435
  onConfirm: () => {
436
- je.current = {
436
+ Ge.current = {
437
437
  id: b.id,
438
- order: O.map((re) => re.id)
439
- }, Pe(""), j(b.id);
438
+ order: O.map((ie) => ie.id)
439
+ }, _e(""), W(b.id);
440
440
  }
441
441
  }
442
442
  ) : null
@@ -455,36 +455,36 @@ function ir({
455
455
  return /* @__PURE__ */ u(
456
456
  "section",
457
457
  {
458
- "aria-labelledby": Se,
458
+ "aria-labelledby": pe,
459
459
  "data-section": "signed-versions",
460
- className: `${pn} ds:flex ds:flex-col ds:gap-[var(--spacing-sm)] ds:text-start`,
460
+ className: `${Rn} ds:flex ds:flex-col ds:gap-[var(--spacing-sm)] ds:text-start`,
461
461
  children: [
462
- /* @__PURE__ */ n("div", { className: ae, children: /* @__PURE__ */ n("div", { className: _n, children: /* @__PURE__ */ n(
462
+ /* @__PURE__ */ n("div", { className: se, children: /* @__PURE__ */ n("div", { className: zn, children: /* @__PURE__ */ n(
463
463
  "h3",
464
464
  {
465
- id: Se,
465
+ id: pe,
466
466
  className: "type-eyebrow ds:m-0 ds:text-[color:var(--muted-foreground)]",
467
467
  children: R("signatureRequest.signedVersions")
468
468
  }
469
469
  ) }) }),
470
- /* @__PURE__ */ n("div", { className: ae, children: /* @__PURE__ */ u("div", { className: "ds:col-[1/-2] ds:min-w-0", children: [
470
+ /* @__PURE__ */ n("div", { className: se, children: /* @__PURE__ */ u("div", { className: "ds:col-[1/-2] ds:min-w-0", children: [
471
471
  /* @__PURE__ */ n(
472
- La,
472
+ za,
473
473
  {
474
474
  loading: o,
475
475
  loadingText: R("signatureRequest.signaturesLoading"),
476
476
  loadedText: R("signatureRequest.signaturesLoaded"),
477
- message: Ie
477
+ message: ye
478
478
  }
479
479
  ),
480
- ye
480
+ ke
481
481
  ] }) })
482
482
  ]
483
483
  }
484
484
  );
485
485
  }
486
- function $a() {
487
- const [i, o] = _(!1), m = ce(!1);
486
+ function Ba() {
487
+ const [i, o] = _(!1), m = oe(!1);
488
488
  return {
489
489
  tooltipProps: {
490
490
  open: i,
@@ -507,18 +507,18 @@ function $a() {
507
507
  }
508
508
  };
509
509
  }
510
- function ya({ id: i, label: o, icon: m, children: l }) {
511
- const p = $a();
510
+ function Ea({ id: i, label: o, icon: m, children: l }) {
511
+ const p = Ba();
512
512
  return /* @__PURE__ */ u(
513
- fn.Root,
513
+ Nn.Root,
514
514
  {
515
515
  id: i,
516
- onOpenChange: (I) => {
517
- I && p.hideTip();
516
+ onOpenChange: (w) => {
517
+ w && p.hideTip();
518
518
  },
519
519
  children: [
520
- /* @__PURE__ */ n(Aa, { label: o, ...p.tooltipProps, children: /* @__PURE__ */ n(fn.Trigger, { asChild: !0, children: /* @__PURE__ */ n(
521
- vn,
520
+ /* @__PURE__ */ n(_a, { label: o, ...p.tooltipProps, children: /* @__PURE__ */ n(Nn.Trigger, { asChild: !0, children: /* @__PURE__ */ n(
521
+ xn,
522
522
  {
523
523
  intent: "ghost",
524
524
  size: "sm",
@@ -528,7 +528,7 @@ function ya({ id: i, label: o, icon: m, children: l }) {
528
528
  }
529
529
  ) }) }),
530
530
  /* @__PURE__ */ n(
531
- fn.Content,
531
+ Nn.Content,
532
532
  {
533
533
  align: "end",
534
534
  onCloseAutoFocus: p.markReturning,
@@ -539,47 +539,47 @@ function ya({ id: i, label: o, icon: m, children: l }) {
539
539
  }
540
540
  );
541
541
  }
542
- function rr({ id: i, when: o, dateTime: m, onConfirm: l }) {
543
- const { t: p } = Mn("ui"), I = $a(), [k, j] = _(!1), R = p("signatureRequest.deleteSignature");
542
+ function dr({ id: i, when: o, dateTime: m, onConfirm: l }) {
543
+ const { t: p } = Fn("ui"), w = Ba(), [k, W] = _(!1), R = p("signatureRequest.deleteSignature");
544
544
  return /* @__PURE__ */ u(
545
- C,
545
+ q,
546
546
  {
547
547
  id: i,
548
548
  open: k,
549
549
  onOpenChange: (Z) => {
550
- Z && I.hideTip(), j(Z);
550
+ Z && w.hideTip(), W(Z);
551
551
  },
552
552
  children: [
553
- /* @__PURE__ */ n(Aa, { label: R, ...I.tooltipProps, children: /* @__PURE__ */ n(C.Trigger, { asChild: !0, children: /* @__PURE__ */ n(
554
- vn,
553
+ /* @__PURE__ */ n(_a, { label: R, ...w.tooltipProps, children: /* @__PURE__ */ n(q.Trigger, { asChild: !0, children: /* @__PURE__ */ n(
554
+ xn,
555
555
  {
556
556
  intent: "destructiveOutline",
557
557
  size: "sm",
558
- icon: /* @__PURE__ */ n(va, {}),
558
+ icon: /* @__PURE__ */ n(xa, {}),
559
559
  "aria-label": R,
560
- ...I.triggerProps
560
+ ...w.triggerProps
561
561
  }
562
562
  ) }) }),
563
563
  /* @__PURE__ */ u(
564
- C.Content,
564
+ q.Content,
565
565
  {
566
566
  variant: "alert",
567
567
  size: "sm",
568
- onCloseAutoFocus: I.markReturning,
568
+ onCloseAutoFocus: w.markReturning,
569
569
  children: [
570
- /* @__PURE__ */ u(C.Header, { children: [
571
- /* @__PURE__ */ n(C.Title, { children: p("signatureRequest.deleteSignatureConfirm") }),
572
- /* @__PURE__ */ n(C.Description, { children: /* @__PURE__ */ n("time", { dateTime: m, children: o }) })
570
+ /* @__PURE__ */ u(q.Header, { children: [
571
+ /* @__PURE__ */ n(q.Title, { children: p("signatureRequest.deleteSignatureConfirm") }),
572
+ /* @__PURE__ */ n(q.Description, { children: /* @__PURE__ */ n("time", { dateTime: m, children: o }) })
573
573
  ] }),
574
- /* @__PURE__ */ u(C.Footer, { children: [
575
- /* @__PURE__ */ n(C.Close, { asChild: !0, children: /* @__PURE__ */ n(L, { intent: "outline", children: p("common.cancel") }) }),
574
+ /* @__PURE__ */ u(q.Footer, { children: [
575
+ /* @__PURE__ */ n(q.Close, { asChild: !0, children: /* @__PURE__ */ n(L, { intent: "outline", children: p("common.cancel") }) }),
576
576
  /* @__PURE__ */ n(
577
577
  L,
578
578
  {
579
579
  intent: "destructive",
580
- startIcon: /* @__PURE__ */ n(va, {}),
580
+ startIcon: /* @__PURE__ */ n(xa, {}),
581
581
  onClick: () => {
582
- l(), j(!1);
582
+ l(), W(!1);
583
583
  },
584
584
  children: R
585
585
  }
@@ -592,41 +592,41 @@ function rr({ id: i, when: o, dateTime: m, onConfirm: l }) {
592
592
  }
593
593
  );
594
594
  }
595
- const Q = "__assign-later__";
596
- function lr(i) {
595
+ const K = "__assign-later__";
596
+ function ur(i) {
597
597
  return i.filter((o) => o.signed !== !0);
598
598
  }
599
- function or(i) {
599
+ function hr(i) {
600
600
  return i.length > 0 && i.every(
601
601
  (o) => o.kind === "document" && o.canCarrySecondary === !0
602
602
  );
603
603
  }
604
- function Xe(i) {
604
+ function en(i) {
605
605
  return i.requiresOperator;
606
606
  }
607
- function za(i, o) {
607
+ function ja(i, o) {
608
608
  return i.filter((m) => m.deleted !== !0 || m.value === o).map(({ deleted: m, ...l }) => l);
609
609
  }
610
- function Ha(i, o) {
610
+ function Ua(i, o) {
611
611
  return i.some(
612
612
  (m) => m.value === o && m.disabled !== !0 && m.deleted !== !0
613
613
  );
614
614
  }
615
- function Fa(i, o) {
615
+ function Wa(i, o) {
616
616
  const m = i.filter((l) => l.disabled === !0 && l.deleted !== !0).map(
617
617
  (l) => l.description ? `${l.label} (${l.description})` : l.label
618
618
  );
619
619
  if (m.length !== 0)
620
620
  return new Intl.ListFormat(o || "en", { type: "unit" }).format(m);
621
621
  }
622
- function st({
622
+ function lt({
623
623
  items: i,
624
624
  channel: o,
625
625
  primaryIsPatient: m
626
626
  }) {
627
- return or(i) ? m ? "patient" : o !== "on-device" ? "channel" : null : i.some((l) => l.kind === "anamnesis") ? "anamnesis" : "documents";
627
+ return hr(i) ? m ? "patient" : o !== "on-device" ? "channel" : null : i.some((l) => l.kind === "anamnesis") ? "anamnesis" : "documents";
628
628
  }
629
- function cr({
629
+ function mr({
630
630
  primaryId: i,
631
631
  secondId: o,
632
632
  channel: m,
@@ -635,33 +635,33 @@ function cr({
635
635
  if (o === i) return "sameAsPrimary";
636
636
  const p = l.find((k) => k.value === o);
637
637
  if (!p || p.isPatient === !0) return "unknownSignee";
638
- const I = (k) => {
639
- var j;
640
- return (!p.availableChannels || p.availableChannels.length === 0 || p.availableChannels.includes(k)) && !((j = p.unavailableChannels) != null && j.some((R) => R.channel === k));
638
+ const w = (k) => {
639
+ var W;
640
+ return (!p.availableChannels || p.availableChannels.length === 0 || p.availableChannels.includes(k)) && !((W = p.unavailableChannels) != null && W.some((R) => R.channel === k));
641
641
  };
642
- return m === "sms" && !I("sms") ? "missingPhone" : (m === "email" || m === "whatsapp") && !I("email") ? "missingEmail" : null;
642
+ return m === "sms" && !w("sms") ? "missingPhone" : (m === "email" || m === "whatsapp") && !w("email") ? "missingEmail" : null;
643
643
  }
644
- const dr = [0, 1, 2], ur = "ds:grid ds:grid-cols-1 ds:@[512px]/person:grid-cols-2 ds:items-center ds:gap-[var(--spacing-sm)] ds:font-normal", hr = "ds:grid ds:grid-cols-1 ds:@[512px]/person:grid-cols-[minmax(0,1fr)_minmax(0,1fr)_max-content] ds:items-center ds:gap-[var(--spacing-sm)] ds:font-normal", mr = "ds:min-w-0 ds:font-medium", gr = "ds:col-span-full ds:min-w-0 ds:font-medium", Vt = "ds:block ds:min-w-0", ka = "ds:!gap-[var(--spacing-sm)] ds:!p-[var(--spacing-sm)]";
645
- function pr({
644
+ const gr = [0, 1, 2], pr = "ds:grid ds:grid-cols-1 ds:@[512px]/person:grid-cols-2 ds:items-center ds:gap-[var(--spacing-sm)] ds:font-normal", fr = "ds:grid ds:grid-cols-1 ds:@[512px]/person:grid-cols-[minmax(0,1fr)_minmax(0,1fr)_max-content] ds:items-center ds:gap-[var(--spacing-sm)] ds:font-normal", vr = "ds:min-w-0 ds:font-medium", br = "ds:col-span-full ds:min-w-0 ds:font-medium", Yt = "ds:block ds:min-w-0", Da = "ds:!gap-[var(--spacing-sm)] ds:!p-[var(--spacing-sm)]";
645
+ function Rr({
646
646
  items: i,
647
647
  loading: o = !1,
648
648
  operatorOptions: m,
649
649
  assignments: l,
650
650
  onAssign: p,
651
- onAssignAllToMe: I,
651
+ onAssignAllToMe: w,
652
652
  busy: k = !1,
653
- showOperatorChannels: j = !1,
653
+ showOperatorChannels: W = !1,
654
654
  operatorChannels: R = {},
655
655
  onOperatorChannel: Z
656
656
  }) {
657
- const { t: $, i18n: Se } = Mn("ui"), Ae = Yt(), Ye = it.map(
657
+ const { t: $, i18n: pe } = Fn("ui"), Pe = ns(), nn = ct.map(
658
658
  (O) => ({
659
659
  value: O,
660
- label: Ae[O].label,
661
- startAdornment: Ae[O].icon
660
+ label: Pe[O].label,
661
+ startAdornment: Pe[O].icon
662
662
  })
663
- ), De = B(), y = B(), ie = B(), Je = /* @__PURE__ */ n(
664
- La,
663
+ ), Le = B(), y = B(), ae = B(), tn = /* @__PURE__ */ n(
664
+ za,
665
665
  {
666
666
  loading: o,
667
667
  loadingText: $("signatureRequest.requiredLoading"),
@@ -669,20 +669,20 @@ function pr({
669
669
  }
670
670
  );
671
671
  if (o)
672
- return /* @__PURE__ */ u(me, { children: [
673
- Je,
672
+ return /* @__PURE__ */ u(ge, { children: [
673
+ tn,
674
674
  /* @__PURE__ */ n(
675
675
  "div",
676
676
  {
677
677
  "aria-busy": "true",
678
678
  className: "ds:flex ds:flex-col ds:gap-[var(--spacing-md)]",
679
- children: dr.map((O) => /* @__PURE__ */ u(
679
+ children: gr.map((O) => /* @__PURE__ */ u(
680
680
  "div",
681
681
  {
682
682
  className: "ds:flex ds:flex-col ds:gap-[var(--spacing-xs)]",
683
683
  children: [
684
- /* @__PURE__ */ n(qe, { size: "md", width: "50%" }),
685
- /* @__PURE__ */ n(qe, { size: "sm", width: "30%" })
684
+ /* @__PURE__ */ n(Ie, { size: "md", width: "50%" }),
685
+ /* @__PURE__ */ n(Ie, { size: "sm", width: "30%" })
686
686
  ]
687
687
  },
688
688
  O
@@ -690,69 +690,69 @@ function pr({
690
690
  }
691
691
  )
692
692
  ] });
693
- const We = i.filter((O) => O.kind === "document"), we = i.filter((O) => O.kind === "anamnesis"), de = i.some(
694
- (O) => Xe(O) && l[O.id] === Q
695
- ), je = [We, we].find(
696
- (O) => O.some(Xe)
697
- ), Ie = Fa(m, Se.language), Pe = (O, ye, M) => {
693
+ const We = i.filter((O) => O.kind === "document"), we = i.filter((O) => O.kind === "anamnesis"), ce = i.some(
694
+ (O) => en(O) && l[O.id] === K
695
+ ), Ge = [We, we].find(
696
+ (O) => O.some(en)
697
+ ), ye = Wa(m, pe.language), _e = (O, ke, M) => {
698
698
  if (O.length === 0) return null;
699
- const b = O === je;
699
+ const b = O === Ge;
700
700
  return /* @__PURE__ */ u(
701
701
  "section",
702
702
  {
703
- className: `${pn} ds:flex ds:flex-col ds:gap-[var(--spacing-sm)]`,
703
+ className: `${Rn} ds:flex ds:flex-col ds:gap-[var(--spacing-sm)]`,
704
704
  children: [
705
- /* @__PURE__ */ u("div", { className: ae, children: [
706
- /* @__PURE__ */ u("div", { className: _n, children: [
705
+ /* @__PURE__ */ u("div", { className: se, children: [
706
+ /* @__PURE__ */ u("div", { className: zn, children: [
707
707
  /* @__PURE__ */ n(
708
708
  "p",
709
709
  {
710
- id: ye,
710
+ id: ke,
711
711
  className: "type-eyebrow ds:text-[color:var(--muted-foreground)]",
712
712
  children: M
713
713
  }
714
714
  ),
715
- b && I ? /* @__PURE__ */ n(
715
+ b && w ? /* @__PURE__ */ n(
716
716
  L,
717
717
  {
718
718
  intent: "outline",
719
719
  size: "sm",
720
- startIcon: /* @__PURE__ */ n(Xt, {}),
720
+ startIcon: /* @__PURE__ */ n(es, {}),
721
721
  disabled: k,
722
- onClick: I,
722
+ onClick: w,
723
723
  children: $("signatureRequest.assignAllToMe")
724
724
  }
725
725
  ) : null
726
726
  ] }),
727
- b && de ? /* @__PURE__ */ n(
728
- U,
727
+ b && ce ? /* @__PURE__ */ n(
728
+ j,
729
729
  {
730
730
  variant: "info",
731
731
  "data-note": "assign-later",
732
- className: `${F} ${ka}`,
733
- children: /* @__PURE__ */ n(U.Description, { children: $("signatureRequest.assignLaterNote") })
732
+ className: `${H} ${Da}`,
733
+ children: /* @__PURE__ */ n(j.Description, { children: $("signatureRequest.assignLaterNote") })
734
734
  }
735
735
  ) : null,
736
- b && !j ? /* @__PURE__ */ n(
737
- U,
736
+ b && !W ? /* @__PURE__ */ n(
737
+ j,
738
738
  {
739
739
  variant: "info",
740
740
  "data-note": "operator-channel",
741
- className: `${F} ${ka}`,
742
- children: /* @__PURE__ */ n(U.Description, { children: $("signatureRequest.operatorChannelNote") })
741
+ className: `${H} ${Da}`,
742
+ children: /* @__PURE__ */ n(j.Description, { children: $("signatureRequest.operatorChannelNote") })
743
743
  }
744
744
  ) : null
745
745
  ] }),
746
- /* @__PURE__ */ n("div", { className: ae, children: /* @__PURE__ */ n(
747
- at,
746
+ /* @__PURE__ */ n("div", { className: se, children: /* @__PURE__ */ n(
747
+ ot,
748
748
  {
749
749
  density: "relaxed",
750
- "aria-labelledby": ye,
751
- className: F,
750
+ "aria-labelledby": ke,
751
+ className: H,
752
752
  children: O.map((E) => {
753
- const ee = Xe(E), z = ee && j, N = ee && l[E.id] !== void 0 && l[E.id] !== Q && l[E.id] !== "";
753
+ const ee = en(E), z = ee && W, x = ee && l[E.id] !== void 0 && l[E.id] !== K && l[E.id] !== "";
754
754
  return /* @__PURE__ */ n(
755
- at.Item,
755
+ ot.Item,
756
756
  {
757
757
  value: E.id,
758
758
  "data-required-item-id": E.id,
@@ -760,23 +760,23 @@ function pr({
760
760
  title: /* @__PURE__ */ u(
761
761
  "span",
762
762
  {
763
- className: z ? hr : ur,
763
+ className: z ? fr : pr,
764
764
  children: [
765
- /* @__PURE__ */ n("span", { className: ee ? mr : gr, children: E.name }),
766
- ee ? /* @__PURE__ */ n("span", { className: Vt, children: /* @__PURE__ */ n(
765
+ /* @__PURE__ */ n("span", { className: ee ? vr : br, children: E.name }),
766
+ ee ? /* @__PURE__ */ n("span", { className: Yt, children: /* @__PURE__ */ n(
767
767
  Ue,
768
768
  {
769
769
  id: `signature-request-item-operator-${E.id}`,
770
- options: za(
770
+ options: ja(
771
771
  m,
772
772
  l[E.id]
773
773
  ),
774
774
  value: l[E.id],
775
- onValueChange: (W) => {
776
- W && Ha(m, W) && p(E.id, W);
775
+ onValueChange: (U) => {
776
+ U && Ua(m, U) && p(E.id, U);
777
777
  },
778
778
  showDescriptions: !0,
779
- "aria-describedby": Ie ? ie : void 0,
779
+ "aria-describedby": ye ? ae : void 0,
780
780
  required: !0,
781
781
  disabled: k,
782
782
  placeholder: $(
@@ -795,13 +795,13 @@ function pr({
795
795
  /* @__PURE__ */ u(
796
796
  "span",
797
797
  {
798
- className: N ? Vt : `${Vt} ds:hidden ds:@[512px]/person:block`,
798
+ className: x ? Yt : `${Yt} ds:hidden ds:@[512px]/person:block`,
799
799
  children: [
800
- N ? /* @__PURE__ */ n(
800
+ x ? /* @__PURE__ */ n(
801
801
  Ue,
802
802
  {
803
803
  id: `signature-request-item-operator-channel-${E.id}`,
804
- options: Ye,
804
+ options: nn,
805
805
  value: R[E.id],
806
806
  adornmentInTrigger: !0,
807
807
  disabled: k,
@@ -809,17 +809,17 @@ function pr({
809
809
  "signatureRequest.itemOperatorChannelLabel",
810
810
  { name: E.name }
811
811
  ),
812
- onValueChange: (W) => {
813
- it.includes(
814
- W
812
+ onValueChange: (U) => {
813
+ ct.includes(
814
+ U
815
815
  ) && (Z == null || Z(
816
816
  E.id,
817
- W
817
+ U
818
818
  ));
819
819
  }
820
820
  }
821
821
  ) : null,
822
- /* @__PURE__ */ n(_a, { meta: Ae })
822
+ /* @__PURE__ */ n(Fa, { meta: Pe })
823
823
  ]
824
824
  }
825
825
  )
@@ -837,18 +837,18 @@ function pr({
837
837
  }
838
838
  );
839
839
  };
840
- return /* @__PURE__ */ u(me, { children: [
841
- Je,
842
- Ie ? /* @__PURE__ */ n("span", { id: ie, className: "ds:sr-only", children: Ie }) : null,
840
+ return /* @__PURE__ */ u(ge, { children: [
841
+ tn,
842
+ ye ? /* @__PURE__ */ n("span", { id: ae, className: "ds:sr-only", children: ye }) : null,
843
843
  /* @__PURE__ */ u("div", { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-lg)] ds:text-start", children: [
844
- Pe(
844
+ _e(
845
845
  We,
846
- De,
846
+ Le,
847
847
  $("signatureRequest.requiredDocumentsHeading", {
848
848
  count: We.length
849
849
  })
850
850
  ),
851
- Pe(
851
+ _e(
852
852
  we,
853
853
  y,
854
854
  $("signatureRequest.requiredAnamnesisHeading", {
@@ -858,7 +858,7 @@ function pr({
858
858
  ] })
859
859
  ] });
860
860
  }
861
- function fr(i, o, { required: m = !1 } = {}) {
861
+ function Nr(i, o, { required: m = !1 } = {}) {
862
862
  switch (i) {
863
863
  case "linkSent":
864
864
  return m ? {
@@ -880,7 +880,7 @@ function fr(i, o, { required: m = !1 } = {}) {
880
880
  };
881
881
  }
882
882
  }
883
- function vr({
883
+ function xr({
884
884
  outcome: i
885
885
  }) {
886
886
  const o = i === "creditsExhausted";
@@ -894,60 +894,60 @@ function vr({
894
894
  {
895
895
  "aria-hidden": "true",
896
896
  className: o ? "ds:text-[color:var(--warning)]" : "ds:text-[color:var(--success)]",
897
- children: o ? /* @__PURE__ */ n(Ui, { className: "ds:size-[var(--icon-size-lg)]" }) : /* @__PURE__ */ n(Wi, { className: "ds:size-[var(--icon-size-lg)]" })
897
+ children: o ? /* @__PURE__ */ n(Vi, { className: "ds:size-[var(--icon-size-lg)]" }) : /* @__PURE__ */ n(Qi, { className: "ds:size-[var(--icon-size-lg)]" })
898
898
  }
899
899
  )
900
900
  }
901
901
  );
902
902
  }
903
- function br(i) {
903
+ function qr(i) {
904
904
  return i === "addSignee" || i === "addSecondSignee";
905
905
  }
906
- function Rr({
906
+ function Cr({
907
907
  options: i,
908
908
  rosterIds: o,
909
909
  rosterCap: m
910
910
  }) {
911
911
  const l = i.find((k) => k.isPatient === !0);
912
912
  if ((l == null ? void 0 : l.isMinor) !== !0) return null;
913
- const p = i.filter((k) => k.isPatient !== !0), I = p.filter(
913
+ const p = i.filter((k) => k.isPatient !== !0), w = p.filter(
914
914
  (k) => o.includes(k.value)
915
915
  );
916
- return I.length === 0 ? p.length === 0 ? "addSignee" : "selectSignee" : I.length > 1 || o.length >= m ? null : p.length > 1 ? "selectSecondSignee" : "addSecondSignee";
916
+ return w.length === 0 ? p.length === 0 ? "addSignee" : "selectSignee" : w.length > 1 || o.length >= m ? null : p.length > 1 ? "selectSecondSignee" : "addSecondSignee";
917
917
  }
918
- const gn = [
918
+ const bn = [
919
919
  "sms",
920
920
  "email",
921
921
  "whatsapp",
922
922
  "on-device",
923
923
  "qr"
924
- ], Oa = [
924
+ ], Aa = [
925
925
  "sms",
926
926
  "email",
927
927
  "whatsapp"
928
- ], Qt = "__create-signee__", Nr = ["operator", "signers"], Ta = "signature-request-batch-channel", Kt = {
928
+ ], Jt = "__create-signee__", Sr = ["operator", "signers"], Pa = "signature-request-batch-channel", Zt = {
929
929
  anamnesis: "signatureRequest.secondSigneeUnavailableAnamnesis",
930
930
  documents: "signatureRequest.secondSigneeUnavailableDocuments",
931
931
  patient: "signatureRequest.secondSigneeUnavailablePatient",
932
932
  channel: "signatureRequest.secondSigneeUnavailableChannel"
933
- }, xr = {
933
+ }, Ir = {
934
934
  sms: "signatureRequest.addMobileNumber",
935
935
  whatsapp: "signatureRequest.addMobileNumber",
936
936
  email: "signatureRequest.addEmailAddress",
937
937
  "on-device": "signatureRequest.editContactDetails",
938
938
  qr: "signatureRequest.editContactDetails"
939
- }, Cr = {
939
+ }, wr = {
940
940
  addSignee: "signatureRequest.minorPatientAddSignee",
941
941
  selectSignee: "signatureRequest.minorPatientSelectSignee",
942
942
  selectSecondSignee: "signatureRequest.minorPatientSelectSecondSignee",
943
943
  addSecondSignee: "signatureRequest.minorPatientAddSecondSignee"
944
- }, qr = {
944
+ }, yr = {
945
945
  sameAsPrimary: "signatureRequest.secondSigneeSameAsPrimary",
946
946
  unknownSignee: "signatureRequest.secondSigneeUnknown",
947
947
  missingPhone: "signatureRequest.secondSigneeMissingPhone",
948
948
  missingEmail: "signatureRequest.secondSigneeMissingEmail"
949
949
  };
950
- function Sr(i, o, m) {
950
+ function kr(i, o, m) {
951
951
  const l = i instanceof Date ? i : new Date(i);
952
952
  if (Number.isNaN(l.getTime())) return null;
953
953
  const p = { hour: "2-digit", minute: "2-digit" };
@@ -962,220 +962,220 @@ function Sr(i, o, m) {
962
962
  }).format(l)
963
963
  });
964
964
  }
965
- function Fe(i, o) {
965
+ function Ae(i, o) {
966
966
  var m;
967
967
  return ((m = i.find((l) => l.value === o)) == null ? void 0 : m.label) ?? "";
968
968
  }
969
- const wr = Di(
969
+ const Or = Mi(
970
970
  ({
971
971
  open: i,
972
972
  onOpenChange: o,
973
973
  operators: m,
974
974
  signerOptions: l,
975
975
  currentOperatorId: p,
976
- allowAssignLater: I = !0,
976
+ allowAssignLater: w = !0,
977
977
  requireOperator: k = !0,
978
- requirePatient: j = !0,
978
+ requirePatient: W = !0,
979
979
  initialOperatorId: R,
980
980
  initialOperatorChannel: Z,
981
981
  initialSigners: $,
982
- maxSigners: Se = 2,
983
- channelMode: Ae = "perSigner",
984
- initialBatchChannel: Ye,
985
- confirmRecipients: De = !1,
982
+ maxSigners: pe = 2,
983
+ channelMode: Pe = "perSigner",
984
+ initialBatchChannel: nn,
985
+ confirmRecipients: Le = !1,
986
986
  busy: y = !1,
987
- error: ie,
988
- title: Je,
987
+ error: ae,
988
+ title: tn,
989
989
  description: We,
990
990
  onRequestSignature: we,
991
- qrCodes: de,
992
- qrPending: je = !1,
993
- onQrDone: Ie,
994
- signatures: Pe,
991
+ qrCodes: ce,
992
+ qrPending: Ge = !1,
993
+ onQrDone: ye,
994
+ signatures: _e,
995
995
  signaturesLoading: O = !1,
996
- showLegalLevel: ye = !0,
996
+ showLegalLevel: ke = !0,
997
997
  onViewSignature: M,
998
998
  onDownloadSignature: b,
999
999
  onShareSignature: E,
1000
1000
  signatureShareTargets: ee,
1001
1001
  onDeleteSignature: z,
1002
- resolveChannels: N,
1003
- requiredItems: W,
1004
- requiredItemsLoading: ge = !1,
1005
- showOperatorChannels: ke = !1,
1006
- outcome: pe,
1007
- onBuyMoreSignatures: re,
1008
- onOutcomeCancel: Jt,
1009
- onAddSignee: le,
1010
- loading: Ze = !1,
1011
- batchChannelPlacement: Ba = "below",
1012
- signerAddAction: Zt = "addRow",
1013
- secondSigneeSlot: lt = !1,
1014
- linkOnDevice: Ua = !1,
1015
- contentProps: Wa
1016
- }, ja) => {
1017
- var ia, ra, la, oa, ca, da;
1018
- const { t: r, i18n: ot } = Mn("ui"), en = ce(0), bn = ce(null), es = ce(null), nn = ce(null), ns = ce(null), ne = ce(null), ct = B(), ts = B(), ss = B(), as = B(), dt = B(), is = B(), rs = B(), Ga = B(), ls = B(), Va = B(), os = B(), Qa = B(), cs = B(), $n = B(), f = W !== void 0 || ge, te = W ? lr(W) : [], K = k && !f, ue = j || f, v = Ae === "batch", Rn = v && Ba === "inline", G = lt && !f && ue && Se >= 2, Le = Ua && K && ue, Nn = (e) => {
1002
+ resolveChannels: x,
1003
+ requiredItems: U,
1004
+ requiredItemsLoading: de = !1,
1005
+ showOperatorChannels: Oe = !1,
1006
+ outcome: fe,
1007
+ onBuyMoreSignatures: ie,
1008
+ onOutcomeCancel: ts,
1009
+ onAddSignee: re,
1010
+ loading: sn = !1,
1011
+ batchChannelPlacement: Ga = "below",
1012
+ signerAddAction: ss = "addRow",
1013
+ secondSigneeSlot: Hn = !1,
1014
+ linkOnDevice: Va = !1,
1015
+ contentProps: Qa
1016
+ }, Ka) => {
1017
+ var ca, da, ua, ha, ma, ga;
1018
+ const { t: r, i18n: ut } = Fn("ui"), an = oe(0), qn = oe(null), as = oe(null), rn = oe(null), is = oe(null), ne = oe(null), ht = B(), rs = B(), ls = B(), os = B(), mt = B(), gt = B(), cs = B(), Xa = B(), ds = B(), Ya = B(), us = B(), Ja = B(), hs = B(), Bn = B(), f = U !== void 0 || de, te = U ? ur(U) : [], X = k && !f, ue = W || f, v = Pe === "batch", Cn = v && Ga === "inline", G = Hn && ue && pe >= 2, Me = Va && X && ue, Sn = (e) => {
1019
1019
  var t;
1020
1020
  return ((t = l.find((s) => s.value === e)) == null ? void 0 : t.isPatient) === !0;
1021
- }, zn = (e, t) => {
1021
+ }, ln = (e, t) => {
1022
1022
  var a, c, d;
1023
- return G ? Nn((a = e[0]) == null ? void 0 : a.signerId) ? 1 : 2 : f ? st({
1023
+ return f ? lt({
1024
1024
  items: te,
1025
1025
  channel: v ? t : ((c = e[0]) == null ? void 0 : c.channel) ?? t,
1026
- primaryIsPatient: Nn((d = e[0]) == null ? void 0 : d.signerId)
1027
- }) === null ? Math.min(Se, 2) : 1 : Se;
1028
- }, [ut, tn] = _(!1), [Ka, ht] = _(!1), [Xa, Ya] = _(pe);
1029
- pe !== Xa && (Ya(pe), ht(!1), pe !== void 0 && tn(!1));
1030
- const fe = (Ka ? void 0 : pe) ?? (W !== void 0 && !ge && te.length === 0 ? "allSigned" : void 0), xn = fe ? fr(fe, r, { required: f }) : null, Cn = (e) => {
1026
+ primaryIsPatient: Sn((d = e[0]) == null ? void 0 : d.signerId)
1027
+ }) === null ? Math.min(pe, 2) : 1 : G ? Sn((a = e[0]) == null ? void 0 : a.signerId) ? 1 : 2 : pe;
1028
+ }, [pt, on] = _(!1), [Za, ft] = _(!1), [ei, ni] = _(fe);
1029
+ fe !== ei && (ni(fe), ft(!1), fe !== void 0 && on(!1));
1030
+ const ve = (Za ? void 0 : fe) ?? (U !== void 0 && !de && te.length === 0 ? "allSigned" : void 0), In = ve ? Nr(ve, r, { required: f }) : null, wn = (e) => {
1031
1031
  var t;
1032
1032
  return new Map(
1033
1033
  (((t = l.find((s) => s.value === e)) == null ? void 0 : t.unavailableChannels) ?? []).map(({ channel: s, reason: a }) => [s, a])
1034
1034
  );
1035
- }, ds = (e, t) => {
1035
+ }, ms = (e, t) => {
1036
1036
  var c;
1037
1037
  const s = ((c = l.find((d) => d.value === e)) == null ? void 0 : c.unavailableChannels) ?? [], a = [];
1038
1038
  for (const d of t) {
1039
- const h = s.find((w) => w.channel === d);
1039
+ const h = s.find((I) => I.channel === d);
1040
1040
  if (!(h != null && h.actionHref) || /^\s*javascript:/i.test(h.actionHref))
1041
1041
  continue;
1042
- const g = h.actionLabel ?? r(xr[d]);
1042
+ const g = h.actionLabel ?? r(Ir[d]);
1043
1043
  a.some(
1044
- (w) => w.href === h.actionHref && w.label === g
1044
+ (I) => I.href === h.actionHref && I.label === g
1045
1045
  ) || a.push({ href: h.actionHref, label: g });
1046
1046
  }
1047
1047
  return a;
1048
- }, mt = (e, t) => {
1048
+ }, vt = (e, t) => {
1049
1049
  var h;
1050
1050
  const s = (h = l.find(
1051
1051
  (g) => g.value === e
1052
- )) == null ? void 0 : h.availableChannels, a = s && s.length > 0 ? gn.filter((g) => s.includes(g)) : gn;
1052
+ )) == null ? void 0 : h.availableChannels, a = s && s.length > 0 ? bn.filter((g) => s.includes(g)) : bn;
1053
1053
  if (!t) return a;
1054
- const c = Cn(e), d = a.filter((g) => t.includes(g));
1054
+ const c = wn(e), d = a.filter((g) => t.includes(g));
1055
1055
  return d.some((g) => !c.has(g)) ? d : a;
1056
- }, _e = (e, t) => {
1057
- const s = Cn(e);
1058
- return mt(e, t).filter(
1056
+ }, $e = (e, t) => {
1057
+ const s = wn(e);
1058
+ return vt(e, t).filter(
1059
1059
  (a) => !s.has(a)
1060
1060
  );
1061
- }, sn = (e) => {
1061
+ }, cn = (e) => {
1062
1062
  const t = e == null ? void 0 : e.operatorAvailableChannels;
1063
- return t && t.length > 0 ? er.filter((s) => t.includes(s)) : it;
1064
- }, qn = (e, t) => {
1065
- const s = _e(e);
1063
+ return t && t.length > 0 ? ar.filter((s) => t.includes(s)) : ct;
1064
+ }, yn = (e, t) => {
1065
+ const s = $e(e);
1066
1066
  return s.includes(t) ? t : s[0] ?? t;
1067
- }, an = l.find(
1067
+ }, dn = l.find(
1068
1068
  (e) => e.isPatient === !0
1069
- ), us = (e) => e === void 0 ? [] : an && an.value !== e ? [e, an.value] : [e], gt = (e) => {
1070
- const t = us(e), s = /* @__PURE__ */ new Map();
1071
- for (const a of gn) {
1072
- if (a === "on-device" || t.some((d) => _e(d).includes(a))) continue;
1073
- const c = t.map((d) => Cn(d).get(a)).find((d) => d !== void 0);
1069
+ ), gs = (e) => e === void 0 ? [] : dn && dn.value !== e ? [e, dn.value] : [e], bt = (e) => {
1070
+ const t = gs(e), s = /* @__PURE__ */ new Map();
1071
+ for (const a of bn) {
1072
+ if (a === "on-device" || t.some((d) => $e(d).includes(a))) continue;
1073
+ const c = t.map((d) => wn(d).get(a)).find((d) => d !== void 0);
1074
1074
  c !== void 0 && s.set(a, c);
1075
1075
  }
1076
1076
  return s;
1077
- }, hs = (e, t) => {
1078
- if (e === void 0) return gn;
1079
- const s = us(e), a = gn.filter(
1080
- (g) => s.some((T) => mt(T).includes(g))
1081
- ), c = gt(e), d = t ? a.filter((g) => t.includes(g)) : a, h = d.some((g) => !c.has(g)) ? d : a;
1082
- return gn.filter(
1077
+ }, ps = (e, t) => {
1078
+ if (e === void 0) return bn;
1079
+ const s = gs(e), a = bn.filter(
1080
+ (g) => s.some((T) => vt(T).includes(g))
1081
+ ), c = bt(e), d = t ? a.filter((g) => t.includes(g)) : a, h = d.some((g) => !c.has(g)) ? d : a;
1082
+ return bn.filter(
1083
1083
  (g) => g === "on-device" || h.includes(g)
1084
1084
  );
1085
- }, Sn = (e, t) => {
1086
- const s = gt(e);
1087
- return hs(e, t).filter(
1085
+ }, kn = (e, t) => {
1086
+ const s = bt(e);
1087
+ return ps(e, t).filter(
1088
1088
  (a) => !s.has(a)
1089
1089
  );
1090
- }, ms = (e, t = !0) => {
1091
- const s = Sn(e), a = (t ? Ye : void 0) ?? (Nn(e) && s.includes("sms") ? "sms" : "email");
1090
+ }, fs = (e, t = !0) => {
1091
+ const s = kn(e), a = (t ? nn : void 0) ?? (Sn(e) && s.includes("sms") ? "sms" : "email");
1092
1092
  return s.includes(a) ? a : s[0];
1093
- }, gs = (ia = m.find(
1093
+ }, vs = (ca = m.find(
1094
1094
  (e) => e.disabled !== !0 && e.deleted !== !0
1095
- )) == null ? void 0 : ia.value, ps = (e) => e === null ? I ? Q : gs ?? Q : e ?? gs ?? (I ? Q : ""), Ja = () => ps(R), Za = () => {
1095
+ )) == null ? void 0 : ca.value, bs = (e) => e === null ? w ? K : vs ?? K : e ?? vs ?? (w ? K : ""), ti = () => bs(R), si = () => {
1096
1096
  const e = $ && $.length > 0 ? $ : l.length > 0 ? [
1097
1097
  {
1098
1098
  signerId: l[0].value,
1099
- channel: qn(l[0].value, "on-device")
1099
+ channel: yn(l[0].value, "on-device")
1100
1100
  }
1101
1101
  ] : [];
1102
1102
  return (G ? e.slice(0, 2) : e).map((t) => {
1103
- const s = qn(t.signerId, t.channel), { skipOtp: a, ...c } = t;
1103
+ const s = yn(t.signerId, t.channel), { skipOtp: a, ...c } = t;
1104
1104
  return {
1105
1105
  ...c,
1106
1106
  channel: s,
1107
1107
  ...s === "on-device" && a !== void 0 ? { skipOtp: a } : {},
1108
- rowId: en.current++
1108
+ rowId: an.current++
1109
1109
  };
1110
1110
  });
1111
- }, ei = N !== void 0 && !f, X = (e, t = !0) => {
1111
+ }, ai = x !== void 0 && !f, Y = (e, t = !0) => {
1112
1112
  var a;
1113
1113
  const s = ((a = m.find((c) => c.value === e)) == null ? void 0 : a.defaultChannel) ?? "email";
1114
- return s === "whatsapp" && !ei || s === "on-device" && !t ? "email" : s;
1115
- }, fs = (e, t) => Z === "on-device" ? t ? "on-device" : X(e, !1) : Z === "whatsapp" ? X(e, t) : Z ?? X(e, t), vs = (e, t, s) => {
1116
- const a = sn(e), c = e.operatorChannel ?? s, d = X(t), h = d === "whatsapp" && !a.includes("whatsapp") ? "email" : d;
1114
+ return s === "whatsapp" && !ai || s === "on-device" && !t ? "email" : s;
1115
+ }, Rs = (e, t) => Z === "on-device" ? t ? "on-device" : Y(e, !1) : Z === "whatsapp" ? Y(e, t) : Z ?? Y(e, t), Ns = (e, t, s) => {
1116
+ const a = cn(e), c = e.operatorChannel ?? s, d = Y(t), h = d === "whatsapp" && !a.includes("whatsapp") ? "email" : d;
1117
1117
  return a.includes(c) ? c : a.includes(h) ? h : a[0];
1118
- }, wn = (e, t, s, a, c = "on-device") => {
1119
- const d = K && e !== Q && e !== "", h = f || G ? s.slice(0, zn(s, c)) : s, g = {};
1118
+ }, On = (e, t, s, a, c = "on-device") => {
1119
+ const d = X && e !== K && e !== "", h = f || G ? s.slice(0, ln(s, c)) : s, g = {};
1120
1120
  if (ue)
1121
1121
  for (const T of h) {
1122
- const w = [...Cn(T.signerId).keys()];
1123
- w.length > 0 && (g[T.signerId] = w);
1122
+ const I = [...wn(T.signerId).keys()];
1123
+ I.length > 0 && (g[T.signerId] = I);
1124
1124
  }
1125
1125
  return {
1126
1126
  operatorId: d ? e : null,
1127
1127
  operatorChannel: d ? t : null,
1128
1128
  signers: ue ? h.map(
1129
- ({ rowId: T, ...w }) => v ? { signerId: w.signerId, channel: c } : w
1129
+ ({ rowId: T, ...I }) => v ? { signerId: I.signerId, channel: c } : I
1130
1130
  ) : [],
1131
1131
  changed: a,
1132
1132
  ...Object.keys(g).length > 0 ? { signerUnavailableChannels: g } : {}
1133
1133
  };
1134
- }, pt = (e, t, s, a, c) => {
1135
- const d = wn(t, s, a, c), h = e(d), g = d.operatorChannel === null ? s : vs(h, t, s), T = d.signers.length, w = a.map((P, Ce) => {
1136
- var Ne, xe;
1137
- if (Ce >= T) return P;
1138
- const J = _e(
1139
- P.signerId,
1140
- (Ne = h.signerAvailableChannels) == null ? void 0 : Ne[P.signerId]
1141
- ), he = ((xe = h.signers.find((He) => He.signerId === P.signerId)) == null ? void 0 : xe.channel) ?? P.channel, Ee = J.includes(he) ? he : J[0] ?? P.channel;
1142
- return Ee === P.channel ? P : { ...P, channel: Ee, skipOtp: void 0 };
1134
+ }, Rt = (e, t, s, a, c) => {
1135
+ const d = On(t, s, a, c), h = e(d), g = d.operatorChannel === null ? s : Ns(h, t, s), T = d.signers.length, I = a.map((A, xe) => {
1136
+ var qe, Ce;
1137
+ if (xe >= T) return A;
1138
+ const Q = $e(
1139
+ A.signerId,
1140
+ (qe = h.signerAvailableChannels) == null ? void 0 : qe[A.signerId]
1141
+ ), he = ((Ce = h.signers.find((Be) => Be.signerId === A.signerId)) == null ? void 0 : Ce.channel) ?? A.channel, Se = Q.includes(he) ? he : Q[0] ?? A.channel;
1142
+ return Se === A.channel ? A : { ...A, channel: Se, skipOtp: void 0 };
1143
1143
  });
1144
- return { operatorChannel: g, rows: w };
1145
- }, bs = (e, t, s, a = "", c = "email") => {
1146
- var P, Ce, J;
1147
- const d = (P = e[0]) == null ? void 0 : P.signerId;
1148
- if (!N) {
1149
- const he = Sn(d);
1144
+ return { operatorChannel: g, rows: I };
1145
+ }, xs = (e, t, s, a = "", c = "email") => {
1146
+ var A, xe, Q;
1147
+ const d = (A = e[0]) == null ? void 0 : A.signerId;
1148
+ if (!x) {
1149
+ const he = kn(d);
1150
1150
  return {
1151
1151
  batch: he.includes(t) ? t : he[0],
1152
1152
  operatorChannel: c
1153
1153
  };
1154
1154
  }
1155
- const h = wn(a, c, e, s, t), g = N(h), T = Sn(
1155
+ const h = On(a, c, e, s, t), g = x(h), T = kn(
1156
1156
  d,
1157
- d === void 0 || (Ce = g.signerAvailableChannels) == null ? void 0 : Ce[d]
1158
- ), w = ((J = g.signers.find((he) => he.signerId === d)) == null ? void 0 : J.channel) ?? t;
1157
+ d === void 0 || (xe = g.signerAvailableChannels) == null ? void 0 : xe[d]
1158
+ ), I = ((Q = g.signers.find((he) => he.signerId === d)) == null ? void 0 : Q.channel) ?? t;
1159
1159
  return {
1160
- batch: T.includes(w) ? w : T.includes(t) ? t : T[0],
1161
- operatorChannel: h.operatorChannel === null ? c : vs(g, a, c)
1160
+ batch: T.includes(I) ? I : T.includes(t) ? t : T[0],
1161
+ operatorChannel: h.operatorChannel === null ? c : Ns(g, a, c)
1162
1162
  };
1163
- }, ni = () => {
1163
+ }, ii = () => {
1164
1164
  var c, d;
1165
- const e = Ja(), t = Za();
1165
+ const e = ti(), t = si();
1166
1166
  if (v) {
1167
- const h = bs(
1167
+ const h = xs(
1168
1168
  t,
1169
- ms((c = t[0]) == null ? void 0 : c.signerId),
1169
+ fs((c = t[0]) == null ? void 0 : c.signerId),
1170
1170
  null,
1171
1171
  e,
1172
- Z ?? X(e)
1172
+ Z ?? Y(e)
1173
1173
  );
1174
1174
  return {
1175
1175
  operator: e,
1176
1176
  rows: t,
1177
1177
  // Required documents mode has no operator row: nothing reads it.
1178
- operatorChannel: N ? h.operatorChannel : fs(
1178
+ operatorChannel: x ? h.operatorChannel : Rs(
1179
1179
  e,
1180
1180
  t.length > 0 && h.batch === "on-device"
1181
1181
  ),
@@ -1184,20 +1184,20 @@ const wr = Di(
1184
1184
  };
1185
1185
  }
1186
1186
  const s = { batchChannel: "on-device", otpOverride: null };
1187
- if (!N)
1187
+ if (!x)
1188
1188
  return {
1189
1189
  operator: e,
1190
1190
  rows: t,
1191
- operatorChannel: fs(
1191
+ operatorChannel: Rs(
1192
1192
  e,
1193
1193
  t.some((h) => h.channel === "on-device")
1194
1194
  ),
1195
1195
  ...s
1196
1196
  };
1197
- const a = pt(
1198
- N,
1197
+ const a = Rt(
1198
+ x,
1199
1199
  e,
1200
- Z ?? X(e),
1200
+ Z ?? Y(e),
1201
1201
  t,
1202
1202
  null
1203
1203
  );
@@ -1207,20 +1207,20 @@ const wr = Di(
1207
1207
  operatorChannel: a.operatorChannel,
1208
1208
  ...s
1209
1209
  };
1210
- }, Rs = () => {
1211
- const e = ni();
1212
- if (!Le || e.operator === Q || e.operator === "")
1210
+ }, qs = () => {
1211
+ const e = ii();
1212
+ if (!Me || e.operator === K || e.operator === "")
1213
1213
  return e;
1214
- const t = e.rows.slice(0, zn(e.rows, e.batchChannel));
1214
+ const t = e.rows.slice(0, ln(e.rows, e.batchChannel));
1215
1215
  if (!(v ? t.length > 0 && e.batchChannel === "on-device" : t.some(
1216
- (c) => c.channel === "on-device" && _e(c.signerId).length > 0
1216
+ (c) => c.channel === "on-device" && $e(c.signerId).length > 0
1217
1217
  ))) {
1218
1218
  if (e.operatorChannel !== "on-device") return e;
1219
- const c = X(e.operator, !1);
1220
- if (!N) return { ...e, operatorChannel: c };
1221
- const d = sn(
1222
- N(
1223
- wn(
1219
+ const c = Y(e.operator, !1);
1220
+ if (!x) return { ...e, operatorChannel: c };
1221
+ const d = cn(
1222
+ x(
1223
+ On(
1224
1224
  e.operator,
1225
1225
  e.operatorChannel,
1226
1226
  e.rows,
@@ -1231,9 +1231,9 @@ const wr = Di(
1231
1231
  ).filter((g) => g !== "on-device"), h = d.includes(c) ? c : d[0];
1232
1232
  return h === void 0 ? e : { ...e, operatorChannel: h };
1233
1233
  }
1234
- return (N ? sn(
1235
- N(
1236
- wn(
1234
+ return (x ? cn(
1235
+ x(
1236
+ On(
1237
1237
  e.operator,
1238
1238
  e.operatorChannel,
1239
1239
  e.rows,
@@ -1242,330 +1242,331 @@ const wr = Di(
1242
1242
  )
1243
1243
  )
1244
1244
  ).includes("on-device") : !0) ? { ...e, operatorChannel: "on-device" } : e;
1245
- }, [In] = _(Rs), [A, ft] = _(In.operator), [q, ve] = _(In.rows), [H, be] = _(
1246
- In.operatorChannel
1247
- ), [S, Ns] = _(
1248
- In.batchChannel
1249
- ), [ti, vt] = _(
1250
- In.otpOverride
1251
- ), [si, yn] = _(!1), bt = zn(q, S), x = f || G ? q.slice(0, bt) : q, [ai, Rt] = _({}), rn = {};
1245
+ }, [Tn] = _(qs), [D, Nt] = _(Tn.operator), [C, be] = _(Tn.rows), [F, Re] = _(
1246
+ Tn.operatorChannel
1247
+ ), [S, Cs] = _(
1248
+ Tn.batchChannel
1249
+ ), [ri, xt] = _(
1250
+ Tn.otpOverride
1251
+ ), [li, Ve] = _(!1), qt = ln(C, S), N = f || G ? C.slice(0, qt) : C, [oi, Ct] = _({}), un = {};
1252
1252
  for (const e of te)
1253
- Xe(e) && (rn[e.id] = ai[e.id] ?? ps(
1253
+ en(e) && (un[e.id] = oi[e.id] ?? bs(
1254
1254
  e.initialOperatorId !== void 0 ? e.initialOperatorId : R
1255
1255
  ));
1256
- const [ii, Nt] = _({}), xt = {};
1256
+ const [ci, St] = _({}), It = {};
1257
1257
  for (const e of te) {
1258
- const t = rn[e.id];
1259
- t === void 0 || t === Q || t === "" || (xt[e.id] = ii[e.id] ?? X(t));
1258
+ const t = un[e.id];
1259
+ t === void 0 || t === K || t === "" || (It[e.id] = ci[e.id] ?? Y(t));
1260
1260
  }
1261
- const xs = (e) => {
1262
- e.length !== 0 && Nt(
1261
+ const Ss = (e) => {
1262
+ e.length !== 0 && St(
1263
1263
  (t) => Object.fromEntries(
1264
1264
  Object.entries(t).filter(([s]) => !e.includes(s))
1265
1265
  )
1266
1266
  );
1267
- }, ri = (e, t) => {
1268
- rn[e] !== t && xs([e]), Rt((s) => ({ ...s, [e]: t }));
1269
- }, li = () => {
1270
- p !== void 0 && (xs(
1267
+ }, di = (e, t) => {
1268
+ un[e] !== t && Ss([e]), Ct((s) => ({ ...s, [e]: t }));
1269
+ }, ui = () => {
1270
+ p !== void 0 && (Ss(
1271
1271
  te.filter(
1272
- (e) => Xe(e) && rn[e.id] !== p
1272
+ (e) => en(e) && un[e.id] !== p
1273
1273
  ).map((e) => e.id)
1274
- ), Rt((e) => {
1274
+ ), Ct((e) => {
1275
1275
  const t = { ...e };
1276
1276
  for (const s of te)
1277
- Xe(s) && (t[s.id] = p);
1277
+ en(s) && (t[s.id] = p);
1278
1278
  return t;
1279
1279
  }));
1280
- }, [Cs, oe] = _(null), [oi, Me] = _(
1280
+ }, [Is, le] = _(null), [hi, ze] = _(
1281
1281
  null
1282
- ), [ci, Hn] = _(!1), [di, kn] = _(0), Ct = !f && (Pe !== void 0 || O), [ui, hi] = _(i);
1283
- i !== ui && (hi(i), i && (Hn(!1), kn(0), ht(!1), tn(!1)));
1284
- const Fn = i && !Ze, qs = ce(Fn);
1285
- Wt(() => {
1286
- if (Fn && !qs.current) {
1287
- const e = Rs();
1288
- ft(e.operator), ve(e.rows), be(e.operatorChannel), Ns(e.batchChannel), vt(e.otpOverride), oe(null), Me(null), Rt({}), Nt({}), yn(!1), tn(!1), Hn(!1), kn(0);
1282
+ ), [mi, jn] = _(!1), [gi, En] = _(0), wt = !f && (_e !== void 0 || O), [pi, fi] = _(i);
1283
+ i !== pi && (fi(i), i && (jn(!1), En(0), ft(!1), on(!1)));
1284
+ const Un = i && !sn && !de, ws = oe(Un);
1285
+ Qt(() => {
1286
+ if (Un && !ws.current) {
1287
+ const e = qs();
1288
+ Nt(e.operator), be(e.rows), Re(e.operatorChannel), Cs(e.batchChannel), xt(e.otpOverride), le(null), ze(null), Ct({}), St({}), Ve(!1), on(!1), jn(!1), En(0);
1289
1289
  }
1290
- qs.current = Fn;
1291
- }, [Fn]);
1292
- const qt = (e) => _e(e).length === 0, Re = v ? x.length > 0 && S === "on-device" : x.some(
1293
- (e) => e.channel === "on-device" && !qt(e.signerId)
1294
- ), ln = N !== void 0;
1295
- Be(() => {
1296
- if (!(ln || !K) && H === "on-device" && !Re) {
1297
- const e = X(A, !1);
1298
- be(e), oe(e);
1290
+ ws.current = Un;
1291
+ }, [Un]);
1292
+ const yt = (e) => $e(e).length === 0, Ne = v ? N.length > 0 && S === "on-device" : N.some(
1293
+ (e) => e.channel === "on-device" && !yt(e.signerId)
1294
+ ), hn = x !== void 0;
1295
+ je(() => {
1296
+ if (!(hn || !X) && F === "on-device" && !Ne) {
1297
+ const e = Y(D, !1);
1298
+ Re(e), le(e);
1299
1299
  }
1300
- }, [H, Re, A, ln, K]);
1301
- const Ss = I ? [{ value: Q, label: r("signatureRequest.assignLater") }] : [], ws = m.map(
1300
+ }, [F, Ne, D, hn, X]);
1301
+ const ys = w ? [{ value: K, label: r("signatureRequest.assignLater") }] : [], ks = m.map(
1302
1302
  ({ value: e, label: t, disabled: s, reason: a, deleted: c }) => ({
1303
1303
  value: e,
1304
1304
  label: t,
1305
1305
  ...s === !0 ? { disabled: !0, ...a ? { description: a } : {} } : {},
1306
1306
  ...c === !0 ? { deleted: !0 } : {}
1307
1307
  })
1308
- ), Bn = f ? [...Ss, ...ws] : [...ws, ...Ss], St = Fa(Bn, ot.language), Is = B(), $e = A === Q, V = Yt(), Y = N ? N(
1309
- wn(A, H, q, null, S)
1310
- ) : void 0, Un = K && !$e && A !== "", ys = ln ? sn(Y).includes("on-device") : !0, ks = (e) => {
1308
+ ), Wn = f ? [...ys, ...ks] : [...ks, ...ys], kt = Wa(Wn, ut.language), Os = B(), Fe = D === K, V = ns(), J = x ? x(
1309
+ On(D, F, C, null, S)
1310
+ ) : void 0, Gn = X && !Fe && D !== "", Ts = hn ? cn(J).includes("on-device") : !0, Es = (e) => {
1311
1311
  var t;
1312
- return _e(
1312
+ return $e(
1313
1313
  e.signerId,
1314
- (t = Y == null ? void 0 : Y.signerAvailableChannels) == null ? void 0 : t[e.signerId]
1314
+ (t = J == null ? void 0 : J.signerAvailableChannels) == null ? void 0 : t[e.signerId]
1315
1315
  ).includes("on-device");
1316
- }, Wn = v ? void 0 : x[0] && ks(x[0]) ? x[0] : x.find(ks), mi = Re || (v ? x.length > 0 : Wn !== void 0), wt = Le && Un && Re && ys, jn = (e) => Le && Re && ys ? "on-device" : e, Gn = (() => {
1317
- if (!ln || !Un) return;
1318
- const e = sn(
1319
- Y
1320
- ).filter((s) => s !== "on-device"), t = X(A, !1);
1316
+ }, Vn = v ? void 0 : N[0] && Es(N[0]) ? N[0] : N.find(Es), vi = Ne || (v ? N.length > 0 : Vn !== void 0), Ot = Me && Gn && Ne && Ts, Qn = (e) => Me && Ne && Ts ? "on-device" : e, Kn = (() => {
1317
+ if (!hn || !Gn) return;
1318
+ const e = cn(
1319
+ J
1320
+ ).filter((s) => s !== "on-device"), t = Y(D, !1);
1321
1321
  return e.includes(t) ? t : e[0];
1322
1322
  })();
1323
- Be(() => {
1324
- if (!(!Le || !Un)) {
1325
- if (wt && H !== "on-device") {
1326
- be("on-device"), oe(null), Me(
1323
+ je(() => {
1324
+ if (!(!Me || !Gn)) {
1325
+ if (Ot && F !== "on-device") {
1326
+ Re("on-device"), le(null), ze(
1327
1327
  r("signatureRequest.operatorChannelChanged", {
1328
1328
  channel: V["on-device"].label
1329
1329
  })
1330
1330
  );
1331
1331
  return;
1332
1332
  }
1333
- Gn !== void 0 && !Re && H === "on-device" && (be(Gn), oe(Gn));
1333
+ Kn !== void 0 && !Ne && F === "on-device" && (Re(Kn), le(Kn));
1334
1334
  }
1335
1335
  }, [
1336
- Le,
1337
- Un,
1338
- wt,
1339
- Re,
1340
- H,
1341
- Gn
1336
+ Me,
1337
+ Gn,
1338
+ Ot,
1339
+ Ne,
1340
+ F,
1341
+ Kn
1342
1342
  ]);
1343
- const Os = (e, t, s) => !Le || e === Q || e === "" ? t : s ? "on-device" : t === "on-device" ? X(e, !1) : t, gi = (e) => e.slice(0, zn(e, S)).some(
1344
- (t) => t.channel === "on-device" && _e(t.signerId).length > 0
1345
- ), Oe = (e, t, s, a, c = []) => {
1346
- if (!N) return;
1343
+ const Ds = (e, t, s) => !Me || e === K || e === "" ? t : s ? "on-device" : t === "on-device" ? Y(e, !1) : t, bi = (e) => e.slice(0, ln(e, S)).some(
1344
+ (t) => t.channel === "on-device" && $e(t.signerId).length > 0
1345
+ ), Te = (e, t, s, a, c = []) => {
1346
+ if (!x) return;
1347
1347
  if (v) {
1348
- ze(s, S, {
1348
+ He(s, S, {
1349
1349
  operatorId: e,
1350
1350
  opChannel: t,
1351
1351
  changed: a
1352
1352
  });
1353
1353
  return;
1354
1354
  }
1355
- const d = pt(
1356
- N,
1355
+ const d = Rt(
1356
+ x,
1357
1357
  e,
1358
- Os(e, t, gi(s)),
1358
+ Ds(e, t, bi(s)),
1359
1359
  s,
1360
1360
  a
1361
1361
  );
1362
- be(d.operatorChannel), ve(d.rows), oe(null);
1362
+ Re(d.operatorChannel), be(d.rows), le(null);
1363
1363
  const h = [];
1364
- K && e !== Q && e !== "" && d.operatorChannel !== t && h.push(
1364
+ X && e !== K && e !== "" && d.operatorChannel !== t && h.push(
1365
1365
  r("signatureRequest.operatorChannelChanged", {
1366
1366
  channel: V[d.operatorChannel].label
1367
1367
  })
1368
- ), d.rows.forEach((T, w) => {
1369
- T.channel !== s[w].channel && h.push(
1368
+ ), d.rows.forEach((T, I) => {
1369
+ T.channel !== s[I].channel && h.push(
1370
1370
  r("signatureRequest.signerChannelChanged", {
1371
- name: Fe(l, T.signerId),
1371
+ name: Ae(l, T.signerId),
1372
1372
  channel: V[T.channel].label
1373
1373
  })
1374
1374
  );
1375
- }), h.push(...c), Me(h.length > 0 ? h.join(" ") : null);
1376
- }, ze = (e, t, {
1375
+ }), h.push(...c), ze(h.length > 0 ? h.join(" ") : null);
1376
+ }, As = (e, t) => f && N.length === 1 && C.length > 1 && e.length > 1 && t > 1, Ps = (e) => r("signatureRequest.secondSigneeReturned", {
1377
+ name: Ae(l, e)
1378
+ }), He = (e, t, {
1377
1379
  primaryChanged: s = !1,
1378
1380
  clearSecond: a = !1,
1379
1381
  userChannel: c = !1,
1380
- operatorId: d = A,
1381
- opChannel: h = H,
1382
+ operatorId: d = D,
1383
+ opChannel: h = F,
1382
1384
  changed: g = "signers"
1383
1385
  } = {}) => {
1384
- var Ee, Ne, xe;
1385
- const T = s ? ms((Ee = e[0]) == null ? void 0 : Ee.signerId, !1) : t, w = bs(
1386
+ var qe, Ce, Be;
1387
+ const T = s ? fs((qe = e[0]) == null ? void 0 : qe.signerId, !1) : t, I = xs(
1386
1388
  e,
1387
1389
  T,
1388
1390
  g,
1389
1391
  d,
1390
- Os(
1392
+ Ds(
1391
1393
  d,
1392
1394
  h,
1393
1395
  e.length > 0 && T === "on-device"
1394
1396
  )
1395
- ), P = w.batch, Ce = e.length > 1 && (a || f && s), J = [];
1396
- if (K && d !== Q && d !== "" && w.operatorChannel !== h && J.push(
1397
+ ), A = I.batch, xe = e.length > 1 && (a || f && s), Q = [];
1398
+ X && d !== K && d !== "" && I.operatorChannel !== h && Q.push(
1397
1399
  r("signatureRequest.operatorChannelChanged", {
1398
- channel: V[w.operatorChannel].label
1400
+ channel: V[I.operatorChannel].label
1399
1401
  })
1400
- ), P !== (c ? t : S) && J.push(
1402
+ ), A !== (c ? t : S) && Q.push(
1401
1403
  r("signatureRequest.signerChannelChanged", {
1402
- name: Fe(l, ((Ne = e[0]) == null ? void 0 : Ne.signerId) ?? ""),
1403
- channel: V[P].label
1404
+ name: Ae(l, ((Ce = e[0]) == null ? void 0 : Ce.signerId) ?? ""),
1405
+ channel: V[A].label
1404
1406
  })
1405
- ), (f || G) && x.length > 1) {
1406
- const He = f ? st({
1407
- items: te,
1408
- channel: P,
1409
- primaryIsPatient: Nn((xe = e[0]) == null ? void 0 : xe.signerId)
1410
- }) : null;
1411
- Ce ? J.push(r("signatureRequest.secondSigneeCleared")) : He !== null && e.length > 1 && J.push(r(Kt[He]));
1412
- }
1413
- ve(Ce ? e.slice(0, 1) : e), K && be(w.operatorChannel), P !== S && vt(null), Ns(P), oe(null), Me(J.length > 0 ? J.join(" ") : null);
1414
- }, Ts = Sn(
1415
- (ra = q[0]) == null ? void 0 : ra.signerId,
1416
- q[0] === void 0 || (la = Y == null ? void 0 : Y.signerAvailableChannels) == null ? void 0 : la[q[0].signerId]
1407
+ );
1408
+ const Se = f ? lt({
1409
+ items: te,
1410
+ channel: A,
1411
+ primaryIsPatient: Sn((Be = e[0]) == null ? void 0 : Be.signerId)
1412
+ }) : null;
1413
+ (f || G) && N.length > 1 ? xe ? Q.push(r("signatureRequest.secondSigneeCleared")) : Se !== null && e.length > 1 && Q.push(r(Zt[Se])) : As(e, ln(e, A)) && !xe && e[1] && Q.push(Ps(e[1].signerId)), Se !== null && Ve(!1), be(xe ? e.slice(0, 1) : e), X && Re(I.operatorChannel), A !== S && xt(null), Cs(A), le(null), ze(Q.length > 0 ? Q.join(" ") : null);
1414
+ }, Ls = kn(
1415
+ (da = C[0]) == null ? void 0 : da.signerId,
1416
+ C[0] === void 0 || (ua = J == null ? void 0 : J.signerAvailableChannels) == null ? void 0 : ua[C[0].signerId]
1417
1417
  );
1418
- v && !Ts.includes(S) && ze(q, Ts[0]);
1419
- const It = v ? q : q.map((e) => {
1420
- const t = _e(e.signerId);
1418
+ v && !Ls.includes(S) && He(C, Ls[0]);
1419
+ const Tt = v ? C : C.map((e) => {
1420
+ const t = $e(e.signerId);
1421
1421
  return t.length === 0 || t.includes(e.channel) ? e : { ...e, channel: t[0], skipOtp: void 0 };
1422
1422
  });
1423
- if (It.some((e, t) => e !== q[t])) {
1424
- const e = N ? pt(
1425
- N,
1426
- A,
1427
- H,
1428
- It,
1423
+ if (Tt.some((e, t) => e !== C[t])) {
1424
+ const e = x ? Rt(
1425
+ x,
1426
+ D,
1427
+ F,
1428
+ Tt,
1429
1429
  "signers"
1430
- ) : { operatorChannel: H, rows: It };
1431
- ve(e.rows), be(e.operatorChannel), oe(null);
1432
- const t = e.rows.filter((s, a) => s.channel !== q[a].channel).map(
1430
+ ) : { operatorChannel: F, rows: Tt };
1431
+ be(e.rows), Re(e.operatorChannel), le(null);
1432
+ const t = e.rows.filter((s, a) => s.channel !== C[a].channel).map(
1433
1433
  (s) => r("signatureRequest.signerChannelChanged", {
1434
- name: Fe(l, s.signerId),
1434
+ name: Ae(l, s.signerId),
1435
1435
  channel: V[s.channel].label
1436
1436
  })
1437
1437
  );
1438
- Me(t.length > 0 ? t.join(" ") : null);
1438
+ ze(t.length > 0 ? t.join(" ") : null);
1439
1439
  }
1440
- const yt = (e, t) => ({
1440
+ const Et = (e, t) => ({
1441
1441
  value: e,
1442
1442
  label: V[t].label,
1443
1443
  startAdornment: V[t].icon
1444
- }), Es = Le ? !mi : !ln && !Re, As = Es ? r("signatureRequest.onDeviceUnavailableHint") : void 0, kt = wt ? r("signatureRequest.operatorOnDeviceLinked") : void 0, Ot = kt ?? As, Ds = (ln ? sn(Y) : it).map((e) => {
1445
- const t = yt(e, e);
1446
- return e === "on-device" ? Es ? { ...t, disabled: !0, description: As } : t : kt ? { ...t, disabled: !0, description: kt } : t;
1447
- }), pi = () => {
1444
+ }), _s = Me ? !vi : !hn && !Ne, Ms = _s ? r("signatureRequest.onDeviceUnavailableHint") : void 0, Dt = Ot ? r("signatureRequest.operatorOnDeviceLinked") : void 0, At = Dt ?? Ms, $s = (hn ? cn(J) : ct).map((e) => {
1445
+ const t = Et(e, e);
1446
+ return e === "on-device" ? _s ? { ...t, disabled: !0, description: Ms } : t : Dt ? { ...t, disabled: !0, description: Dt } : t;
1447
+ }), Ri = () => {
1448
1448
  if (v) {
1449
- ze(q, "on-device", {
1449
+ He(C, "on-device", {
1450
1450
  opChannel: "on-device",
1451
1451
  changed: "operator"
1452
1452
  });
1453
1453
  return;
1454
1454
  }
1455
- if (!Wn) return;
1456
- const e = q.map(
1457
- (s) => s.rowId === Wn.rowId ? { ...s, channel: "on-device", skipOtp: void 0 } : s
1455
+ if (!Vn) return;
1456
+ const e = C.map(
1457
+ (s) => s.rowId === Vn.rowId ? { ...s, channel: "on-device", skipOtp: void 0 } : s
1458
1458
  ), t = r("signatureRequest.signerChannelChanged", {
1459
- name: Fe(l, Wn.signerId),
1459
+ name: Ae(l, Vn.signerId),
1460
1460
  channel: V["on-device"].label
1461
1461
  });
1462
- if (N) {
1463
- Oe(A, "on-device", e, "operator", [t]);
1462
+ if (x) {
1463
+ Te(D, "on-device", e, "operator", [t]);
1464
1464
  return;
1465
1465
  }
1466
- ve(e), be("on-device"), oe(null), Me(t);
1467
- }, Tt = /* @__PURE__ */ n(_a, { meta: V }), Et = x.map((e) => e.signerId), on = l.find(
1468
- (e) => !Et.includes(e.value) && !(f && e.isPatient === !0)
1469
- ), fi = !y && x.length < bt && on !== void 0, Te = f || v || G ? (oa = x[0]) == null ? void 0 : oa.signerId : void 0, On = Nn(Te), vi = v ? S : ((ca = x[0]) == null ? void 0 : ca.channel) ?? S, Ps = f ? st({
1466
+ be(e), Re("on-device"), le(null), ze(t);
1467
+ }, Pt = /* @__PURE__ */ n(Fa, { meta: V }), Lt = N.map((e) => e.signerId), Qe = l.find(
1468
+ (e) => !Lt.includes(e.value) && !(f && e.isPatient === !0)
1469
+ ), Ni = !y && N.length < qt && Qe !== void 0, Ee = f || v || G ? (ha = N[0]) == null ? void 0 : ha.signerId : void 0, Dn = Sn(Ee), xi = v ? S : ((ma = N[0]) == null ? void 0 : ma.channel) ?? S, An = f ? lt({
1470
1470
  items: te,
1471
- channel: vi,
1472
- primaryIsPatient: On
1473
- }) : null, At = f && !ge && te.length > 0 && Ps !== null && l.length > 1 ? r(Kt[Ps]) : null, Vn = (f || G) && x.length > 1 ? cr({
1474
- primaryId: Te,
1475
- secondId: x[1].signerId,
1476
- channel: v ? S : x[1].channel,
1471
+ channel: xi,
1472
+ primaryIsPatient: Dn
1473
+ }) : null, Xn = f && !de && te.length > 0 && pe >= 2 && An !== null && l.length > 1 && // "Only on this device" promises a seat: someone must be free to take it.
1474
+ (An !== "channel" || Qe !== void 0) ? r(Zt[An]) : null, _t = (e) => Xn && An === e ? gt : void 0, Yn = (f || G) && N.length > 1 ? mr({
1475
+ primaryId: Ee,
1476
+ secondId: N[1].signerId,
1477
+ channel: v ? S : N[1].channel,
1477
1478
  options: l
1478
- }) : null, Ls = G && x.length < 2, Dt = l.filter(
1479
- (e) => e.isPatient !== !0 && !Et.includes(e.value)
1480
- ), bi = G && (x.length === 0 || On), _s = Ls && !bi && Dt.length > 0, Ms = _s && si, $s = Ls && On && l.some((e) => e.isPatient !== !0) ? r("signatureRequest.secondSigneeUnavailablePatient") : null, Ge = lt && !f ? _s && !Ms ? "openSlot" : null : Zt === "createSignee" ? le !== void 0 ? "createSignee" : null : l.length > 1 ? "addRow" : null, zs = Ge === "createSignee", Hs = le !== void 0 && !f && (lt || Zt === "createSignee"), Fs = (e) => Hs ? [
1479
+ }) : null, zs = G && N.length < 2, Mt = l.filter(
1480
+ (e) => e.isPatient !== !0 && !Lt.includes(e.value)
1481
+ ), qi = G && (N.length === 0 || Dn || An !== null), Fs = zs && !qi && Mt.length > 0, Hs = Fs && li, Bs = !f && zs && Dn && l.some((e) => e.isPatient !== !0) ? r("signatureRequest.secondSigneeUnavailablePatient") : null, Ke = Hn ? Fs && !Hs ? "openSlot" : null : ss === "createSignee" ? re !== void 0 ? "createSignee" : null : l.length > 1 && (!f || pe >= 2) ? "addRow" : null, js = Ke === "createSignee", Us = re !== void 0 && (Hn || !f && ss === "createSignee"), Ws = (e) => Us ? [
1481
1482
  ...e,
1482
1483
  {
1483
- value: Qt,
1484
+ value: Jt,
1484
1485
  label: r("signatureRequest.newSignatory"),
1485
1486
  separatorBefore: !0,
1486
1487
  intent: "action"
1487
1488
  }
1488
- ] : [...e], Pt = Sn(
1489
- (an == null ? void 0 : an.value) ?? Te
1490
- ).includes("sms"), cn = (f || v) && On && !Pt, Lt = v && S === "on-device" && (cn || (ti ?? !Pt)), Ri = v && x.length > 0 && (cn || Lt), _t = (e) => f && e === 0, Mt = (e, t) => e.channel === "on-device" && (_t(t) ? cn || (e.skipOtp ?? !Pt) : e.skipOtp === !0), Tn = ue && !(f && ge), En = Tn ? Rr({
1489
+ ] : [...e], $t = kn(
1490
+ (dn == null ? void 0 : dn.value) ?? Ee
1491
+ ).includes("sms"), mn = (f || v) && Dn && !$t, zt = v && S === "on-device" && (mn || (ri ?? !$t)), Ci = v && N.length > 0 && (mn || zt), Ft = (e) => f && e === 0, Ht = (e, t) => e.channel === "on-device" && (Ft(t) ? mn || (e.skipOtp ?? !$t) : e.skipOtp === !0), Pn = ue && !(f && de), Ln = Pn ? Cr({
1491
1492
  options: l,
1492
- rosterIds: x.map((e) => e.signerId),
1493
- rosterCap: bt
1494
- }) : null, $t = En !== null && br(En) && le !== void 0 && !zs, Bs = f && le !== void 0 && !zs && !$t && !l.some((e) => e.isPatient !== !0), Qn = $t || Bs, Us = ce(Qn);
1495
- Be(() => {
1493
+ rosterIds: N.map((e) => e.signerId),
1494
+ rosterCap: qt
1495
+ }) : null, Bt = Ln !== null && qr(Ln) && re !== void 0 && !js, Gs = f && !Hn && re !== void 0 && !js && !Bt && !l.some((e) => e.isPatient !== !0), Jn = Bt || Gs, Vs = oe(Jn);
1496
+ je(() => {
1496
1497
  var e;
1497
- if (Us.current && !Qn) {
1498
+ if (Vs.current && !Jn) {
1498
1499
  const t = document.activeElement;
1499
1500
  if (t === null || t === document.body || t.getAttribute("role") === "dialog") {
1500
- const a = bn.current;
1501
+ const a = qn.current;
1501
1502
  (e = a && !a.disabled ? a : ne.current) == null || e.focus();
1502
1503
  }
1503
1504
  }
1504
- Us.current = Qn;
1505
- }, [Qn]);
1506
- const Ni = (e, t) => {
1507
- ve(
1505
+ Vs.current = Jn;
1506
+ }, [Jn]);
1507
+ const Si = (e, t) => {
1508
+ be(
1508
1509
  (s) => s.map(
1509
1510
  (a) => a.rowId === e ? { ...a, ...t } : a
1510
1511
  )
1511
1512
  );
1512
- }, xi = () => {
1513
- if (!on) return;
1513
+ }, Ii = () => {
1514
+ if (!Qe) return;
1514
1515
  if (v) {
1515
- ze(
1516
+ He(
1516
1517
  [
1517
- ...q,
1518
+ ...C,
1518
1519
  {
1519
- signerId: on.value,
1520
+ signerId: Qe.value,
1520
1521
  channel: S,
1521
- rowId: en.current++
1522
+ rowId: an.current++
1522
1523
  }
1523
1524
  ],
1524
1525
  S
1525
1526
  );
1526
1527
  return;
1527
1528
  }
1528
- const e = qn(
1529
- on.value,
1529
+ const e = yn(
1530
+ Qe.value,
1530
1531
  f ? "on-device" : "sms"
1531
1532
  );
1532
- if (N) {
1533
- Oe(
1534
- A,
1535
- H,
1533
+ if (x) {
1534
+ Te(
1535
+ D,
1536
+ F,
1536
1537
  [
1537
- ...q,
1538
+ ...C,
1538
1539
  {
1539
- signerId: on.value,
1540
+ signerId: Qe.value,
1540
1541
  channel: e,
1541
- rowId: en.current++
1542
+ rowId: an.current++
1542
1543
  }
1543
1544
  ],
1544
1545
  "signers"
1545
1546
  );
1546
1547
  return;
1547
1548
  }
1548
- ve((t) => [
1549
+ be((t) => [
1549
1550
  ...t,
1550
1551
  {
1551
- signerId: on.value,
1552
+ signerId: Qe.value,
1552
1553
  channel: e,
1553
- rowId: en.current++
1554
+ rowId: an.current++
1554
1555
  }
1555
1556
  ]);
1556
- }, Ci = (e) => {
1557
+ }, wi = (e) => {
1557
1558
  var a, c;
1558
- if (!Dt.some((d) => d.value === e)) return;
1559
- (a = ne.current) == null || a.focus(), nn.current = "second";
1560
- const t = q.slice(0, 1);
1559
+ if (!Mt.some((d) => d.value === e)) return;
1560
+ (a = ne.current) == null || a.focus(), rn.current = "second";
1561
+ const t = C.slice(0, 1);
1561
1562
  if (v) {
1562
- ze(
1563
+ He(
1563
1564
  [
1564
1565
  ...t,
1565
1566
  {
1566
1567
  signerId: e,
1567
1568
  channel: S,
1568
- rowId: en.current++
1569
+ rowId: an.current++
1569
1570
  }
1570
1571
  ],
1571
1572
  S
@@ -1576,60 +1577,60 @@ const wr = Di(
1576
1577
  ...t,
1577
1578
  {
1578
1579
  signerId: e,
1579
- channel: qn(e, ((c = t[0]) == null ? void 0 : c.channel) ?? "sms"),
1580
- rowId: en.current++
1580
+ channel: yn(e, ((c = t[0]) == null ? void 0 : c.channel) ?? "sms"),
1581
+ rowId: an.current++
1581
1582
  }
1582
1583
  ];
1583
- if (N) {
1584
- Oe(A, H, s, "signers");
1584
+ if (x) {
1585
+ Te(D, F, s, "signers");
1585
1586
  return;
1586
1587
  }
1587
- ve(s);
1588
+ be(s);
1588
1589
  };
1589
- Wt(() => {
1590
+ Qt(() => {
1590
1591
  var s;
1591
- const e = nn.current;
1592
+ const e = rn.current;
1592
1593
  if (e === null) return;
1593
- nn.current = null, (s = (e === "slot" ? es : e === "second" ? ns : bn).current) == null || s.focus();
1594
+ rn.current = null, (s = (e === "slot" ? as : e === "second" ? is : qn).current) == null || s.focus();
1594
1595
  });
1595
- const qi = () => {
1596
- nn.current = "slot", yn(!0);
1597
- }, Si = () => {
1596
+ const yi = () => {
1597
+ rn.current = "slot", Ve(!0);
1598
+ }, ki = () => {
1598
1599
  var e;
1599
- (e = ne.current) == null || e.focus(), nn.current = "add", yn(!1);
1600
- }, wi = (e) => {
1600
+ (e = ne.current) == null || e.focus(), rn.current = "add", Ve(!1);
1601
+ }, Oi = (e) => {
1601
1602
  var t, s;
1602
- if (G ? ((t = ne.current) == null || t.focus(), nn.current = "add", yn(!1)) : (s = bn.current) == null || s.focus(), v) {
1603
- ze(
1604
- q.filter((a) => a.rowId !== e),
1603
+ if (G ? ((t = ne.current) == null || t.focus(), rn.current = "add", Ve(!1)) : (s = qn.current) == null || s.focus(), v) {
1604
+ He(
1605
+ C.filter((a) => a.rowId !== e),
1605
1606
  S
1606
1607
  );
1607
1608
  return;
1608
1609
  }
1609
- if (N) {
1610
- Oe(
1611
- A,
1612
- H,
1613
- q.filter((a) => a.rowId !== e),
1610
+ if (x) {
1611
+ Te(
1612
+ D,
1613
+ F,
1614
+ C.filter((a) => a.rowId !== e),
1614
1615
  "signers"
1615
1616
  );
1616
1617
  return;
1617
1618
  }
1618
- ve(
1619
+ be(
1619
1620
  (a) => a.filter((c) => c.rowId !== e)
1620
1621
  );
1621
- }, Ws = ue && !v && x.some((e) => qt(e.signerId)), js = ue && (v ? x.length > 0 && S === "qr" : x.some((e) => e.channel === "qr")), Gs = !v && x.some(
1622
- (e, t) => Mt(e, t) && !qt(e.signerId)
1623
- ), zt = (e) => new Intl.ListFormat(ot.language || "en", { type: "unit" }).format(
1622
+ }, Qs = ue && !v && N.some((e) => yt(e.signerId)), Ks = ue && (v ? N.length > 0 && S === "qr" : N.some((e) => e.channel === "qr")), Xs = !v && N.some(
1623
+ (e, t) => Ht(e, t) && !yt(e.signerId)
1624
+ ), jt = (e) => new Intl.ListFormat(ut.language || "en", { type: "unit" }).format(
1624
1625
  e
1625
- ), Vs = (e, t) => e.map((s) => {
1626
+ ), Ys = (e, t) => e.map((s) => {
1626
1627
  const a = t.get(s);
1627
- return a === void 0 ? yt(s, s) : {
1628
- ...yt(s, s),
1628
+ return a === void 0 ? Et(s, s) : {
1629
+ ...Et(s, s),
1629
1630
  disabled: !0,
1630
1631
  description: a
1631
1632
  };
1632
- }), Qs = (e, t, s) => {
1633
+ }), Js = (e, t, s) => {
1633
1634
  const a = /* @__PURE__ */ new Map();
1634
1635
  for (const c of e) {
1635
1636
  const d = t.get(c);
@@ -1639,31 +1640,31 @@ const wr = Di(
1639
1640
  ]);
1640
1641
  }
1641
1642
  if (a.size !== 0)
1642
- return zt(s ? [...a.keys()] : [...a].map(
1643
- ([c, d]) => `${zt(d)} (${c})`
1643
+ return jt(s ? [...a.keys()] : [...a].map(
1644
+ ([c, d]) => `${jt(d)} (${c})`
1644
1645
  ));
1645
- }, Ht = hs(
1646
- Te,
1647
- Te === void 0 || (da = Y == null ? void 0 : Y.signerAvailableChannels) == null ? void 0 : da[Te]
1648
- ), Ft = gt(Te), Ks = Vs(
1649
- Ht,
1650
- Ft
1651
- ), Bt = Qs(
1652
- Ht,
1653
- Ft,
1646
+ }, Ut = ps(
1647
+ Ee,
1648
+ Ee === void 0 || (ga = J == null ? void 0 : J.signerAvailableChannels) == null ? void 0 : ga[Ee]
1649
+ ), Wt = bt(Ee), Zs = Ys(
1650
+ Ut,
1651
+ Wt
1652
+ ), Gt = Js(
1653
+ Ut,
1654
+ Wt,
1654
1655
  !1
1655
- ), Ii = v ? ds(
1656
- Te,
1657
- Ht.filter((e) => Ft.has(e))
1658
- ) : [], Xs = (e, t) => e.length > 0 ? /* @__PURE__ */ n(
1656
+ ), Ti = v ? ms(
1657
+ Ee,
1658
+ Ut.filter((e) => Wt.has(e))
1659
+ ) : [], ea = (e, t) => e.length > 0 ? /* @__PURE__ */ n(
1659
1660
  "div",
1660
1661
  {
1661
1662
  "data-note": "contact-actions",
1662
1663
  role: t ? "group" : void 0,
1663
1664
  "aria-label": t,
1664
- className: `${F} type-body-sm ds:flex ds:flex-wrap ds:gap-x-[var(--spacing-md)]`,
1665
+ className: `${H} type-body-sm ds:flex ds:flex-wrap ds:gap-x-[var(--spacing-md)]`,
1665
1666
  children: e.map((s) => /* @__PURE__ */ n(
1666
- Mi,
1667
+ Hi,
1667
1668
  {
1668
1669
  href: s.href,
1669
1670
  disabled: y,
@@ -1673,249 +1674,251 @@ const wr = Di(
1673
1674
  `${s.href} ${s.label}`
1674
1675
  ))
1675
1676
  }
1676
- ) : null, Ys = (e, t) => {
1677
+ ) : null, na = (e, t) => {
1677
1678
  var s, a;
1678
1679
  return t === "email" ? (s = e == null ? void 0 : e.contact) == null ? void 0 : s.email : (a = e == null ? void 0 : e.contact) == null ? void 0 : a.phone;
1679
- }, Kn = [];
1680
- if (K && !$e && A !== "" && Oa.includes(H)) {
1681
- const e = m.find((t) => t.value === A);
1682
- Kn.push({
1680
+ }, Zn = [];
1681
+ if (X && !Fe && D !== "" && Aa.includes(F)) {
1682
+ const e = m.find((t) => t.value === D);
1683
+ Zn.push({
1683
1684
  key: "operator",
1684
1685
  role: "operator",
1685
- name: (e == null ? void 0 : e.label) ?? A,
1686
- channel: H,
1687
- contact: Ys(e, H)
1686
+ name: (e == null ? void 0 : e.label) ?? D,
1687
+ channel: F,
1688
+ contact: na(e, F)
1688
1689
  });
1689
1690
  }
1690
1691
  if (ue)
1691
- for (const e of x) {
1692
+ for (const e of N) {
1692
1693
  const t = v ? S : e.channel;
1693
- if (!Oa.includes(t)) continue;
1694
+ if (!Aa.includes(t)) continue;
1694
1695
  const s = l.find(
1695
1696
  (a) => a.value === e.signerId
1696
1697
  );
1697
- Kn.push({
1698
+ Zn.push({
1698
1699
  key: `signer-${e.rowId}`,
1699
1700
  role: "signer",
1700
1701
  name: (s == null ? void 0 : s.label) ?? e.signerId,
1701
1702
  channel: t,
1702
- contact: Ys(s, t)
1703
+ contact: na(s, t)
1703
1704
  });
1704
1705
  }
1705
- const yi = () => {
1706
+ const Ei = () => {
1706
1707
  var e;
1707
- if (!(Ws || Vn !== null)) {
1708
- if (De && !ut && Kn.length > 0) {
1709
- (e = ne.current) == null || e.focus(), tn(!0);
1708
+ if (!(Qs || Yn !== null)) {
1709
+ if (Le && !pt && Zn.length > 0) {
1710
+ (e = ne.current) == null || e.focus(), on(!0);
1710
1711
  return;
1711
1712
  }
1712
- Js();
1713
+ ta();
1713
1714
  }
1714
- }, Js = () => {
1715
+ }, ta = () => {
1715
1716
  var s;
1716
- Hn(js), js && ((s = ne.current) == null || s.focus(), kn(0));
1717
- const e = x.map(
1717
+ jn(Ks), Ks && ((s = ne.current) == null || s.focus(), En(0));
1718
+ const e = N.map(
1718
1719
  ({ rowId: a, ...c }, d) => v ? {
1719
1720
  signerId: c.signerId,
1720
1721
  channel: S,
1721
1722
  // The batch's OTP waiver rides on the main signer.
1722
- ...d === 0 && S === "on-device" ? { skipOtp: Lt } : {}
1723
- } : _t(d) && c.channel === "on-device" ? { ...c, skipOtp: Mt(c, d) } : c
1723
+ ...d === 0 && S === "on-device" ? { skipOtp: zt } : {}
1724
+ } : Ft(d) && c.channel === "on-device" ? { ...c, skipOtp: Ht(c, d) } : c
1724
1725
  ), t = v ? { signMode: S } : {};
1725
1726
  if (f) {
1726
1727
  const a = {};
1727
1728
  let c = null;
1728
1729
  for (const h of te) {
1729
- if (!Xe(h)) continue;
1730
- const g = rn[h.id], T = g === Q || g === "" || g === void 0 ? null : g;
1730
+ if (!en(h)) continue;
1731
+ const g = un[h.id], T = g === K || g === "" || g === void 0 ? null : g;
1731
1732
  a[h.id] = T, c ?? (c = T);
1732
1733
  }
1733
1734
  const d = {};
1734
1735
  for (const [h, g] of Object.entries(
1735
1736
  a
1736
1737
  ))
1737
- g !== null && (d[h] = xt[h]);
1738
+ g !== null && (d[h] = It[h]);
1738
1739
  we({
1739
1740
  operatorId: c,
1740
1741
  operatorChannel: null,
1741
1742
  signers: e,
1742
1743
  ...t,
1743
1744
  operatorAssignments: a,
1744
- ...ke ? { operatorChannels: d } : {},
1745
+ ...Oe ? { operatorChannels: d } : {},
1745
1746
  requiredItemIds: te.map((h) => h.id)
1746
1747
  });
1747
1748
  return;
1748
1749
  }
1749
1750
  we({
1750
- operatorId: !k || $e ? null : A,
1751
- operatorChannel: !k || $e ? null : H,
1752
- signers: j ? e : [],
1753
- ...j ? t : {}
1751
+ operatorId: !k || Fe ? null : D,
1752
+ operatorChannel: !k || Fe ? null : F,
1753
+ signers: W ? e : [],
1754
+ ...W ? t : {}
1754
1755
  });
1755
1756
  };
1756
- Be(() => {
1757
+ je(() => {
1757
1758
  var e;
1758
- ie && (Hn(!1), ut && ((e = ne.current) == null || e.focus()), tn(!1));
1759
- }, [ie]);
1760
- const dn = ((de == null ? void 0 : de.length) ?? 0) > 0, Ve = dn || !ie && (je || ci), Xn = ue ? x.filter(
1759
+ ae && (jn(!1), pt && ((e = ne.current) == null || e.focus()), on(!1));
1760
+ }, [ae]);
1761
+ const gn = ((ce == null ? void 0 : ce.length) ?? 0) > 0, Xe = gn || !ae && (Ge || mi), et = ue ? N.filter(
1761
1762
  (e) => (v ? S : e.channel) === "qr"
1762
1763
  ).map((e) => e.signerId) : [];
1763
- for (const e of de ?? [])
1764
- Xn.includes(e.signerId) || Xn.push(e.signerId);
1765
- const An = Xn.length, Qe = Math.min(di, Math.max(An - 1, 0)), Ke = Xn[Qe], un = Ke === void 0 ? "" : Fe(l, Ke), Dn = de == null ? void 0 : de.find((e) => e.signerId === Ke), Zs = Dn ? Sr(Dn.expiresAt, ot.language || "en", r) : null, ki = Qe >= An - 1, ea = dn && An > 1, Yn = ut && !Ve, na = i && Ve && !fe ? `${dn}:${Qe}` : null;
1766
- Be(() => {
1764
+ for (const e of ce ?? [])
1765
+ et.includes(e.signerId) || et.push(e.signerId);
1766
+ const _n = et.length, Ye = Math.min(gi, Math.max(_n - 1, 0)), Je = et[Ye], pn = Je === void 0 ? "" : Ae(l, Je), Mn = ce == null ? void 0 : ce.find((e) => e.signerId === Je), sa = Mn ? kr(Mn.expiresAt, ut.language || "en", r) : null, Di = Ye >= _n - 1, aa = gn && _n > 1, nt = pt && !Xe, ia = i && Xe && !ve ? `${gn}:${Ye}` : null;
1767
+ je(() => {
1767
1768
  var e;
1768
- na !== null && ((e = ne.current) == null || e.focus());
1769
- }, [na]);
1770
- const ta = i && fe ? fe : null;
1771
- Be(() => {
1769
+ ia !== null && ((e = ne.current) == null || e.focus());
1770
+ }, [ia]);
1771
+ const ra = i && ve ? ve : null;
1772
+ je(() => {
1772
1773
  var e;
1773
- ta !== null && ((e = ne.current) == null || e.focus());
1774
- }, [ta]);
1775
- const Jn = Ze && !fe;
1776
- Wt(() => {
1774
+ ra !== null && ((e = ne.current) == null || e.focus());
1775
+ }, [ra]);
1776
+ const tt = sn && !ve;
1777
+ Qt(() => {
1777
1778
  var t;
1778
- if (!i || !Ze) return;
1779
+ if (!i || !sn) return;
1779
1780
  const e = document.activeElement;
1780
1781
  (e === null || e === document.body) && ((t = ne.current) == null || t.focus());
1781
- }, [i, Ze]);
1782
- const sa = v ? /* @__PURE__ */ u(me, { children: [
1782
+ }, [i, sn]);
1783
+ const la = v ? /* @__PURE__ */ u(ge, { children: [
1783
1784
  /* @__PURE__ */ n(
1784
1785
  Ue,
1785
1786
  {
1786
- id: Ta,
1787
- options: Ks,
1787
+ id: Pa,
1788
+ options: Zs,
1788
1789
  value: S,
1789
1790
  adornmentInTrigger: !0,
1790
1791
  showDescriptions: !0,
1791
1792
  disabled: y,
1792
1793
  "aria-label": r("signatureRequest.channelLabel"),
1793
- "aria-describedby": Bt ? ls : void 0,
1794
+ "aria-describedby": [Gt ? ds : null, _t("channel")].filter(Boolean).join(" ") || void 0,
1794
1795
  onValueChange: (e) => {
1795
- Ks.some(
1796
+ Zs.some(
1796
1797
  (s) => s.value === e && !s.disabled
1797
- ) && ze(q, e, {
1798
+ ) && He(C, e, {
1798
1799
  userChannel: !0
1799
1800
  });
1800
1801
  }
1801
1802
  }
1802
1803
  ),
1803
- Bt ? /* @__PURE__ */ n("span", { id: ls, className: "ds:sr-only", children: Bt }) : null
1804
- ] }) : null, aa = v ? /* @__PURE__ */ u(me, { children: [
1805
- Xs(
1806
- Ii,
1807
- Fe(l, Te ?? "")
1804
+ Gt ? /* @__PURE__ */ n("span", { id: ds, className: "ds:sr-only", children: Gt }) : null
1805
+ ] }) : null, oa = v ? /* @__PURE__ */ u(ge, { children: [
1806
+ ea(
1807
+ Ti,
1808
+ Ae(l, Ee ?? "")
1808
1809
  ),
1809
- S === "on-device" ? /* @__PURE__ */ n("div", { className: F, children: /* @__PURE__ */ n(
1810
- ga,
1810
+ S === "on-device" ? /* @__PURE__ */ n("div", { className: H, children: /* @__PURE__ */ n(
1811
+ ba,
1811
1812
  {
1812
1813
  label: r("signatureRequest.noOtp"),
1813
- checked: Lt,
1814
- disabled: y || cn,
1815
- "aria-describedby": cn ? $n : void 0,
1816
- onCheckedChange: (e) => vt(e)
1814
+ checked: zt,
1815
+ disabled: y || mn,
1816
+ "aria-describedby": mn ? Bn : void 0,
1817
+ onCheckedChange: (e) => xt(e)
1817
1818
  }
1818
1819
  ) }) : null,
1819
- Ri ? /* @__PURE__ */ n(U, { variant: "warning", id: $n, className: F, children: /* @__PURE__ */ n(U.Description, { children: r("signatureRequest.noOtpWarning") }) }) : null
1820
- ] }) : null, Oi = dn ? Dn ? un ? r("signatureRequest.qrCaptionNamed", { name: un }) : r("signatureRequest.qrCaption") : (
1820
+ Ci ? /* @__PURE__ */ n(j, { variant: "warning", id: Bn, className: H, children: /* @__PURE__ */ n(j.Description, { children: r("signatureRequest.noOtpWarning") }) }) : null
1821
+ ] }) : null, Ai = gn ? Mn ? pn ? r("signatureRequest.qrCaptionNamed", { name: pn }) : r("signatureRequest.qrCaption") : (
1821
1822
  // The error alert in the body carries the message (and announces
1822
1823
  // itself); the description only names whose slot this is.
1823
- un || Ke
1824
+ pn || Je
1824
1825
  ) : r("signatureRequest.qrPending");
1825
- return /* @__PURE__ */ n("div", { ref: ja, className: "ds:contents", "data-component": "signature-request", children: /* @__PURE__ */ n(Ea, { children: /* @__PURE__ */ n(C, { open: i, onOpenChange: o, children: /* @__PURE__ */ u(
1826
- C.Content,
1826
+ return /* @__PURE__ */ n("div", { ref: Ka, className: "ds:contents", "data-component": "signature-request", children: /* @__PURE__ */ n(La, { children: /* @__PURE__ */ n(q, { open: i, onOpenChange: o, children: /* @__PURE__ */ u(
1827
+ q.Content,
1827
1828
  {
1828
1829
  size: "lg",
1829
1830
  scroll: "body",
1830
1831
  hideCloseButton: !0,
1831
1832
  onOpenAutoFocus: (e) => {
1832
1833
  var t;
1833
- !Ve && !Ct && !fe && !Ze || (e.preventDefault(), (t = ne.current) == null || t.focus());
1834
+ !Xe && !wt && !ve && !sn || (e.preventDefault(), (t = ne.current) == null || t.focus());
1834
1835
  },
1835
- ...Wa,
1836
+ ...Qa,
1836
1837
  children: [
1837
- /* @__PURE__ */ u(C.Header, { children: [
1838
+ /* @__PURE__ */ u(q.Header, { children: [
1838
1839
  /* @__PURE__ */ n(
1839
- C.Title,
1840
+ q.Title,
1840
1841
  {
1841
1842
  ref: ne,
1842
1843
  tabIndex: -1,
1843
- "aria-describedby": xn ? ss : Jn ? as : Ve ? ea ? `${ct} ${ts}` : ct : Yn ? dt : void 0,
1844
+ "aria-describedby": In ? ls : tt ? os : Xe ? aa ? `${ht} ${rs}` : ht : nt ? mt : void 0,
1844
1845
  className: "ds:outline-none",
1845
- children: xn ? xn.title : !Jn && Ve ? r("signatureRequest.qrTitle") : !Jn && Yn ? r("signatureRequest.confirmTitle") : Je ?? r(
1846
+ children: In ? In.title : !tt && Xe ? r("signatureRequest.qrTitle") : !tt && nt ? r("signatureRequest.confirmTitle") : tn ?? r(
1846
1847
  f ? "signatureRequest.requiredTitle" : "signatureRequest.title"
1847
1848
  )
1848
1849
  }
1849
1850
  ),
1850
- xn ? /* @__PURE__ */ n(C.Description, { asChild: !0, children: /* @__PURE__ */ n("div", { children: /* @__PURE__ */ n("p", { id: ss, children: xn.description }) }) }) : Jn ? /* @__PURE__ */ n(C.Description, { asChild: !0, children: /* @__PURE__ */ n("div", { children: /* @__PURE__ */ n("p", { id: as, children: r("signatureRequest.loading") }) }) }) : Ve ? /* @__PURE__ */ n(C.Description, { asChild: !0, children: /* @__PURE__ */ n("div", { children: /* @__PURE__ */ u(
1851
+ In ? /* @__PURE__ */ n(q.Description, { asChild: !0, children: /* @__PURE__ */ n("div", { children: /* @__PURE__ */ n("p", { id: ls, children: In.description }) }) }) : tt ? /* @__PURE__ */ n(q.Description, { asChild: !0, children: /* @__PURE__ */ n("div", { children: /* @__PURE__ */ n("p", { id: os, children: r("signatureRequest.loading") }) }) }) : Xe ? /* @__PURE__ */ n(q.Description, { asChild: !0, children: /* @__PURE__ */ n("div", { children: /* @__PURE__ */ u(
1851
1852
  "div",
1852
1853
  {
1853
- id: ct,
1854
+ id: ht,
1854
1855
  className: "ds:flex ds:flex-col ds:gap-[var(--spacing-xs)]",
1855
1856
  children: [
1856
- /* @__PURE__ */ n("p", { children: Oi }),
1857
- Zs ? /* @__PURE__ */ n("p", { children: Zs }) : null
1857
+ /* @__PURE__ */ n("p", { children: Ai }),
1858
+ sa ? /* @__PURE__ */ n("p", { children: sa }) : null
1858
1859
  ]
1859
1860
  }
1860
- ) }) }) : Yn ? /* @__PURE__ */ n(C.Description, { asChild: !0, children: /* @__PURE__ */ n("div", { children: /* @__PURE__ */ n("p", { id: dt, children: r("signatureRequest.confirmDescription") }) }) }) : /* @__PURE__ */ n(C.Description, { children: We ?? r(
1861
- f ? "signatureRequest.requiredDescription" : Ct ? (
1861
+ ) }) }) : nt ? /* @__PURE__ */ n(q.Description, { asChild: !0, children: /* @__PURE__ */ n("div", { children: /* @__PURE__ */ n("p", { id: mt, children: r(
1862
+ f ? "signatureRequest.requiredConfirmDescription" : "signatureRequest.confirmDescription"
1863
+ ) }) }) }) : /* @__PURE__ */ n(q.Description, { children: We ?? r(
1864
+ f ? "signatureRequest.requiredDescription" : wt ? (
1862
1865
  // The table says whether there are signed
1863
1866
  // versions, so the header describes the form.
1864
1867
  "signatureRequest.requestDescription"
1865
1868
  ) : "signatureRequest.noSignedVersions"
1866
1869
  ) })
1867
1870
  ] }),
1868
- fe ? /* @__PURE__ */ u(me, { children: [
1869
- /* @__PURE__ */ n(C.Body, { children: /* @__PURE__ */ n(vr, { outcome: fe }) }),
1870
- /* @__PURE__ */ u(C.Footer, { children: [
1871
- fe === "creditsExhausted" && re ? /* @__PURE__ */ n(
1871
+ ve ? /* @__PURE__ */ u(ge, { children: [
1872
+ /* @__PURE__ */ n(q.Body, { children: /* @__PURE__ */ n(xr, { outcome: ve }) }),
1873
+ /* @__PURE__ */ u(q.Footer, { children: [
1874
+ ve === "creditsExhausted" && ie ? /* @__PURE__ */ n(
1872
1875
  L,
1873
1876
  {
1874
1877
  intent: "primary",
1875
- startIcon: /* @__PURE__ */ n(Yi, {}),
1876
- onClick: re,
1878
+ startIcon: /* @__PURE__ */ n(nr, {}),
1879
+ onClick: ie,
1877
1880
  children: r("signatureRequest.buyMoreSignatures")
1878
1881
  }
1879
1882
  ) : null,
1880
- fe === "creditsExhausted" && pe === "creditsExhausted" && Jt ? /* @__PURE__ */ n(
1883
+ ve === "creditsExhausted" && fe === "creditsExhausted" && ts ? /* @__PURE__ */ n(
1881
1884
  L,
1882
1885
  {
1883
1886
  intent: "ghost",
1884
1887
  onClick: () => {
1885
1888
  var e;
1886
- (e = ne.current) == null || e.focus(), ht(!0), Jt();
1889
+ (e = ne.current) == null || e.focus(), ft(!0), ts();
1887
1890
  },
1888
1891
  children: r("signatureRequest.outcomeCancel")
1889
1892
  }
1890
1893
  ) : null,
1891
- /* @__PURE__ */ n(C.Close, { asChild: !0, children: /* @__PURE__ */ n(L, { intent: "outline", children: r("signatureRequest.close") }) })
1894
+ /* @__PURE__ */ n(q.Close, { asChild: !0, children: /* @__PURE__ */ n(L, { intent: "outline", children: r("signatureRequest.close") }) })
1892
1895
  ] })
1893
- ] }) : Ze ? /* @__PURE__ */ u(me, { children: [
1896
+ ] }) : sn ? /* @__PURE__ */ u(ge, { children: [
1894
1897
  /* @__PURE__ */ n(
1895
- C.Body,
1898
+ q.Body,
1896
1899
  {
1897
1900
  "aria-busy": "true",
1898
1901
  "data-note": "loading",
1899
1902
  className: "ds:flex ds:flex-col ds:gap-[var(--spacing-lg)]",
1900
- children: Nr.filter(
1901
- (e) => e === "operator" && K || e === "signers" && ue
1903
+ children: Sr.filter(
1904
+ (e) => e === "operator" && X || e === "signers" && ue
1902
1905
  ).map((e, t) => /* @__PURE__ */ u(
1903
1906
  "div",
1904
1907
  {
1905
- className: `${pn} ds:flex ds:flex-col ds:gap-[var(--spacing-sm)]`,
1908
+ className: `${Rn} ds:flex ds:flex-col ds:gap-[var(--spacing-sm)]`,
1906
1909
  children: [
1907
- /* @__PURE__ */ n("div", { className: ae, children: /* @__PURE__ */ n("div", { className: _n, children: /* @__PURE__ */ n(qe, { size: "sm", width: "30%", stagger: t }) }) }),
1908
- /* @__PURE__ */ u("div", { className: ae, children: [
1909
- /* @__PURE__ */ n("div", { className: nt, children: /* @__PURE__ */ n(
1910
- qe,
1910
+ /* @__PURE__ */ n("div", { className: se, children: /* @__PURE__ */ n("div", { className: zn, children: /* @__PURE__ */ n(Ie, { size: "sm", width: "30%", stagger: t }) }) }),
1911
+ /* @__PURE__ */ u("div", { className: se, children: [
1912
+ /* @__PURE__ */ n("div", { className: it, children: /* @__PURE__ */ n(
1913
+ Ie,
1911
1914
  {
1912
1915
  variant: "circular",
1913
1916
  size: "sm",
1914
1917
  stagger: t + 1
1915
1918
  }
1916
1919
  ) }),
1917
- /* @__PURE__ */ n("div", { className: jt, children: /* @__PURE__ */ n(
1918
- qe,
1920
+ /* @__PURE__ */ n("div", { className: Kt, children: /* @__PURE__ */ n(
1921
+ Ie,
1919
1922
  {
1920
1923
  variant: "rounded",
1921
1924
  height: "var(--min-target-size)",
@@ -1929,29 +1932,29 @@ const wr = Di(
1929
1932
  ))
1930
1933
  }
1931
1934
  ),
1932
- /* @__PURE__ */ u(C.Footer, { children: [
1933
- /* @__PURE__ */ n(L, { intent: "primary", startIcon: /* @__PURE__ */ n(ba, {}), disabled: !0, children: r("signatureRequest.requestSignature") }),
1934
- /* @__PURE__ */ n(C.Close, { asChild: !0, children: /* @__PURE__ */ n(L, { intent: "outline", children: r("signatureRequest.close") }) })
1935
+ /* @__PURE__ */ u(q.Footer, { children: [
1936
+ /* @__PURE__ */ n(L, { intent: "primary", startIcon: /* @__PURE__ */ n(qa, {}), disabled: !0, children: r("signatureRequest.requestSignature") }),
1937
+ /* @__PURE__ */ n(q.Close, { asChild: !0, children: /* @__PURE__ */ n(L, { intent: "outline", children: r("signatureRequest.close") }) })
1935
1938
  ] })
1936
- ] }) : Ve ? /* @__PURE__ */ u(me, { children: [
1937
- /* @__PURE__ */ n(C.Body, { className: "ds:flex ds:flex-col ds:items-center ds:gap-[var(--spacing-sm)] ds:text-center", children: dn ? /* @__PURE__ */ u(me, { children: [
1938
- ea ? (
1939
+ ] }) : Xe ? /* @__PURE__ */ u(ge, { children: [
1940
+ /* @__PURE__ */ n(q.Body, { className: "ds:flex ds:flex-col ds:items-center ds:gap-[var(--spacing-sm)] ds:text-center", children: gn ? /* @__PURE__ */ u(ge, { children: [
1941
+ aa ? (
1939
1942
  // Also describes the heading, so screen readers hear
1940
1943
  // the position when Previous or Next moves focus there.
1941
1944
  /* @__PURE__ */ n(
1942
1945
  "p",
1943
1946
  {
1944
- id: ts,
1947
+ id: rs,
1945
1948
  className: "type-label ds:text-[var(--muted-foreground)]",
1946
1949
  children: r("signatureRequest.qrStepCount", {
1947
- current: Qe + 1,
1948
- total: An
1950
+ current: Ye + 1,
1951
+ total: _n
1949
1952
  })
1950
1953
  }
1951
1954
  )
1952
1955
  ) : null,
1953
- un ? /* @__PURE__ */ n("p", { className: "type-title-item ds:break-words", children: un }) : null,
1954
- Dn ? (
1956
+ pn ? /* @__PURE__ */ n("p", { className: "type-title-item ds:break-words", children: pn }) : null,
1957
+ Mn ? (
1955
1958
  // The QrCode's own name speaks of check-in, so the
1956
1959
  // pattern names the code and hides the inner figure.
1957
1960
  // `lg` keeps a long signing link at a module size a
@@ -1961,11 +1964,11 @@ const wr = Di(
1961
1964
  {
1962
1965
  role: "img",
1963
1966
  "aria-label": r("signatureRequest.qrCodeLabel"),
1964
- "data-signer-id": Ke,
1967
+ "data-signer-id": Je,
1965
1968
  children: /* @__PURE__ */ n(
1966
- Pi,
1969
+ $i,
1967
1970
  {
1968
- value: Dn.url,
1971
+ value: Mn.url,
1969
1972
  variant: "framed",
1970
1973
  size: "lg",
1971
1974
  decorative: !0
@@ -1974,13 +1977,13 @@ const wr = Di(
1974
1977
  }
1975
1978
  )
1976
1979
  ) : /* @__PURE__ */ n(
1977
- U,
1980
+ j,
1978
1981
  {
1979
1982
  variant: "error",
1980
1983
  className: "ds:text-start",
1981
- "data-signer-id": Ke,
1982
- children: /* @__PURE__ */ n(U.Description, { children: r("signatureRequest.qrMissing", {
1983
- name: un || Ke
1984
+ "data-signer-id": Je,
1985
+ children: /* @__PURE__ */ n(j.Description, { children: r("signatureRequest.qrMissing", {
1986
+ name: pn || Je
1984
1987
  }) })
1985
1988
  }
1986
1989
  )
@@ -1988,29 +1991,29 @@ const wr = Di(
1988
1991
  // Waiting for the server: the spinner's status role
1989
1992
  // announces the wait politely.
1990
1993
  /* @__PURE__ */ n("div", { className: "ds:flex ds:flex-col ds:items-center ds:gap-[var(--spacing-sm)] ds:py-[var(--spacing-xl)]", children: /* @__PURE__ */ n(
1991
- Li,
1994
+ zi,
1992
1995
  {
1993
1996
  size: "lg",
1994
1997
  label: r("signatureRequest.qrPending")
1995
1998
  }
1996
1999
  ) })
1997
2000
  ) }),
1998
- /* @__PURE__ */ n(C.Footer, { children: dn ? /* @__PURE__ */ u(me, { children: [
1999
- An > 1 ? /* @__PURE__ */ n(
2001
+ /* @__PURE__ */ n(q.Footer, { children: gn ? /* @__PURE__ */ u(ge, { children: [
2002
+ _n > 1 ? /* @__PURE__ */ n(
2000
2003
  L,
2001
2004
  {
2002
2005
  intent: "outline",
2003
- disabled: Qe === 0,
2004
- onClick: () => kn(Qe - 1),
2006
+ disabled: Ye === 0,
2007
+ onClick: () => En(Ye - 1),
2005
2008
  children: r("signatureRequest.qrPrevious")
2006
2009
  }
2007
2010
  ) : null,
2008
- ki ? /* @__PURE__ */ n(
2011
+ Di ? /* @__PURE__ */ n(
2009
2012
  L,
2010
2013
  {
2011
2014
  intent: "primary",
2012
2015
  onClick: () => {
2013
- Ie == null || Ie(), o(!1);
2016
+ ye == null || ye(), o(!1);
2014
2017
  },
2015
2018
  children: r("signatureRequest.qrDone")
2016
2019
  }
@@ -2018,19 +2021,19 @@ const wr = Di(
2018
2021
  L,
2019
2022
  {
2020
2023
  intent: "primary",
2021
- onClick: () => kn(Qe + 1),
2024
+ onClick: () => En(Ye + 1),
2022
2025
  children: r("signatureRequest.qrNext")
2023
2026
  }
2024
2027
  )
2025
- ] }) : /* @__PURE__ */ n(C.Close, { asChild: !0, children: /* @__PURE__ */ n(L, { intent: "outline", children: r("signatureRequest.close") }) }) })
2026
- ] }) : Yn ? /* @__PURE__ */ u(me, { children: [
2027
- /* @__PURE__ */ u(C.Body, { children: [
2028
- /* @__PURE__ */ n(at, { "aria-labelledby": dt, children: Kn.map((e) => /* @__PURE__ */ n(
2029
- at.Item,
2028
+ ] }) : /* @__PURE__ */ n(q.Close, { asChild: !0, children: /* @__PURE__ */ n(L, { intent: "outline", children: r("signatureRequest.close") }) }) })
2029
+ ] }) : nt ? /* @__PURE__ */ u(ge, { children: [
2030
+ /* @__PURE__ */ u(q.Body, { children: [
2031
+ /* @__PURE__ */ n(ot, { "aria-labelledby": mt, children: Zn.map((e) => /* @__PURE__ */ n(
2032
+ ot.Item,
2030
2033
  {
2031
2034
  "data-recipient": e.role,
2032
2035
  leading: /* @__PURE__ */ n(
2033
- Zn,
2036
+ st,
2034
2037
  {
2035
2038
  "aria-hidden": "true",
2036
2039
  name: e.name,
@@ -2059,22 +2062,22 @@ const wr = Di(
2059
2062
  },
2060
2063
  e.key
2061
2064
  )) }),
2062
- ie ? /* @__PURE__ */ n(
2063
- U,
2065
+ ae ? /* @__PURE__ */ n(
2066
+ j,
2064
2067
  {
2065
2068
  variant: "error",
2066
2069
  className: "ds:mt-[var(--spacing-md)]",
2067
- children: /* @__PURE__ */ n(U.Description, { children: ie })
2070
+ children: /* @__PURE__ */ n(j.Description, { children: ae })
2068
2071
  }
2069
2072
  ) : null
2070
2073
  ] }),
2071
- /* @__PURE__ */ u(C.Footer, { children: [
2074
+ /* @__PURE__ */ u(q.Footer, { children: [
2072
2075
  /* @__PURE__ */ n(
2073
2076
  L,
2074
2077
  {
2075
2078
  intent: "primary",
2076
- startIcon: /* @__PURE__ */ n(ji, {}),
2077
- onClick: Js,
2079
+ startIcon: /* @__PURE__ */ n(Ki, {}),
2080
+ onClick: ta,
2078
2081
  loading: y,
2079
2082
  children: r("signatureRequest.confirmSend")
2080
2083
  }
@@ -2086,21 +2089,21 @@ const wr = Di(
2086
2089
  disabled: y,
2087
2090
  onClick: () => {
2088
2091
  var e;
2089
- (e = ne.current) == null || e.focus(), tn(!1);
2092
+ (e = ne.current) == null || e.focus(), on(!1);
2090
2093
  },
2091
2094
  children: r("signatureRequest.confirmBack")
2092
2095
  }
2093
2096
  )
2094
2097
  ] })
2095
- ] }) : /* @__PURE__ */ u(me, { children: [
2096
- /* @__PURE__ */ u(C.Body, { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-lg)]", children: [
2097
- Ct ? /* @__PURE__ */ u(me, { children: [
2098
+ ] }) : /* @__PURE__ */ u(ge, { children: [
2099
+ /* @__PURE__ */ u(q.Body, { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-lg)]", children: [
2100
+ wt ? /* @__PURE__ */ u(ge, { children: [
2098
2101
  /* @__PURE__ */ n(
2099
- ir,
2102
+ cr,
2100
2103
  {
2101
- signatures: Pe,
2104
+ signatures: _e,
2102
2105
  loading: O,
2103
- showLegalLevel: ye,
2106
+ showLegalLevel: ke,
2104
2107
  onView: M,
2105
2108
  onDownload: b,
2106
2109
  onShare: E,
@@ -2108,108 +2111,108 @@ const wr = Di(
2108
2111
  onDelete: z
2109
2112
  }
2110
2113
  ),
2111
- K || Tn ? /* @__PURE__ */ n(pa, { decorative: !0 }) : null
2114
+ X || Pn ? /* @__PURE__ */ n(Ra, { decorative: !0 }) : null
2112
2115
  ] }) : null,
2113
2116
  f ? /* @__PURE__ */ n(
2114
- pr,
2117
+ Rr,
2115
2118
  {
2116
2119
  items: te,
2117
- loading: ge,
2118
- operatorOptions: Bn,
2119
- assignments: rn,
2120
- onAssign: ri,
2121
- showOperatorChannels: ke,
2122
- operatorChannels: xt,
2123
- onOperatorChannel: (e, t) => Nt((s) => ({
2120
+ loading: de,
2121
+ operatorOptions: Wn,
2122
+ assignments: un,
2123
+ onAssign: di,
2124
+ showOperatorChannels: Oe,
2125
+ operatorChannels: It,
2126
+ onOperatorChannel: (e, t) => St((s) => ({
2124
2127
  ...s,
2125
2128
  [e]: t
2126
2129
  })),
2127
- onAssignAllToMe: p !== void 0 ? li : void 0,
2130
+ onAssignAllToMe: p !== void 0 ? ui : void 0,
2128
2131
  busy: y
2129
2132
  }
2130
2133
  ) : null,
2131
- K ? /* @__PURE__ */ u(
2134
+ X ? /* @__PURE__ */ u(
2132
2135
  "section",
2133
2136
  {
2134
- className: `${pn} ds:flex ds:flex-col ds:gap-[var(--spacing-sm)] ds:text-start`,
2137
+ className: `${Rn} ds:flex ds:flex-col ds:gap-[var(--spacing-sm)] ds:text-start`,
2135
2138
  children: [
2136
- /* @__PURE__ */ n("div", { className: ae, children: /* @__PURE__ */ u("div", { className: _n, children: [
2139
+ /* @__PURE__ */ n("div", { className: se, children: /* @__PURE__ */ u("div", { className: zn, children: [
2137
2140
  /* @__PURE__ */ n("p", { className: "type-eyebrow ds:text-[color:var(--muted-foreground)]", children: r("signatureRequest.operatorSection") }),
2138
2141
  p !== void 0 ? /* @__PURE__ */ n(
2139
2142
  L,
2140
2143
  {
2141
2144
  intent: "outline",
2142
2145
  size: "sm",
2143
- startIcon: /* @__PURE__ */ n(Xt, {}),
2146
+ startIcon: /* @__PURE__ */ n(es, {}),
2144
2147
  disabled: y,
2145
2148
  onClick: () => {
2146
- if (ft(p), N) {
2147
- Oe(
2149
+ if (Nt(p), x) {
2150
+ Te(
2148
2151
  p,
2149
- jn(
2150
- X(
2152
+ Qn(
2153
+ Y(
2151
2154
  p
2152
2155
  )
2153
2156
  ),
2154
- q,
2157
+ C,
2155
2158
  "operator"
2156
2159
  );
2157
2160
  return;
2158
2161
  }
2159
- be(
2160
- jn(
2161
- X(
2162
+ Re(
2163
+ Qn(
2164
+ Y(
2162
2165
  p,
2163
- Re
2166
+ Ne
2164
2167
  )
2165
2168
  )
2166
- ), oe(null);
2169
+ ), le(null);
2167
2170
  },
2168
2171
  children: r("signatureRequest.assignToMe")
2169
2172
  }
2170
2173
  ) : null
2171
2174
  ] }) }),
2172
- /* @__PURE__ */ u("div", { className: ae, "data-person-row": "operator", children: [
2173
- /* @__PURE__ */ n("div", { className: nt, children: /* @__PURE__ */ n(
2174
- Zn,
2175
+ /* @__PURE__ */ u("div", { className: se, "data-person-row": "operator", children: [
2176
+ /* @__PURE__ */ n("div", { className: it, children: /* @__PURE__ */ n(
2177
+ st,
2175
2178
  {
2176
2179
  "aria-hidden": "true",
2177
- name: $e ? void 0 : Fe(m, A),
2180
+ name: Fe ? void 0 : Ae(m, D),
2178
2181
  size: "sm"
2179
2182
  }
2180
2183
  ) }),
2181
- /* @__PURE__ */ u("div", { className: Na, children: [
2184
+ /* @__PURE__ */ u("div", { className: Sa, children: [
2182
2185
  /* @__PURE__ */ n(
2183
2186
  Ue,
2184
2187
  {
2185
- options: za(
2186
- Bn,
2187
- A
2188
+ options: ja(
2189
+ Wn,
2190
+ D
2188
2191
  ),
2189
- value: A,
2192
+ value: D,
2190
2193
  showDescriptions: !0,
2191
- "aria-describedby": St ? Is : void 0,
2194
+ "aria-describedby": kt ? Os : void 0,
2192
2195
  onValueChange: (e) => {
2193
- if (!(!e || !Ha(Bn, e))) {
2194
- if (ft(e), N) {
2195
- Oe(
2196
+ if (!(!e || !Ua(Wn, e))) {
2197
+ if (Nt(e), x) {
2198
+ Te(
2196
2199
  e,
2197
- e === Q ? "email" : jn(
2198
- X(e)
2200
+ e === K ? "email" : Qn(
2201
+ Y(e)
2199
2202
  ),
2200
- q,
2203
+ C,
2201
2204
  "operator"
2202
2205
  );
2203
2206
  return;
2204
2207
  }
2205
- be(
2206
- e === Q ? "email" : jn(
2207
- X(
2208
+ Re(
2209
+ e === K ? "email" : Qn(
2210
+ Y(
2208
2211
  e,
2209
- Re
2212
+ Ne
2210
2213
  )
2211
2214
  )
2212
- ), oe(null);
2215
+ ), le(null);
2213
2216
  }
2214
2217
  },
2215
2218
  required: !0,
@@ -2220,221 +2223,222 @@ const wr = Di(
2220
2223
  "aria-label": r("signatureRequest.operatorSection")
2221
2224
  }
2222
2225
  ),
2223
- St ? /* @__PURE__ */ n(
2226
+ kt ? /* @__PURE__ */ n(
2224
2227
  "span",
2225
2228
  {
2226
- id: Is,
2229
+ id: Os,
2227
2230
  className: "ds:sr-only",
2228
- children: St
2231
+ children: kt
2229
2232
  }
2230
2233
  ) : null
2231
2234
  ] }),
2232
2235
  /* @__PURE__ */ u(
2233
2236
  "div",
2234
2237
  {
2235
- className: $e ? `${tt} ds:hidden ds:@[512px]/person:block` : tt,
2238
+ className: Fe ? `${rt} ds:hidden ds:@[512px]/person:block` : rt,
2236
2239
  children: [
2237
- $e ? null : /* @__PURE__ */ n(
2240
+ Fe ? null : /* @__PURE__ */ n(
2238
2241
  Ue,
2239
2242
  {
2240
2243
  id: "signature-request-operator-channel",
2241
- options: Ds,
2242
- value: H,
2244
+ options: $s,
2245
+ value: F,
2243
2246
  adornmentInTrigger: !0,
2244
2247
  showDescriptions: !0,
2245
2248
  disabled: y,
2246
2249
  "aria-label": r(
2247
2250
  "signatureRequest.operatorChannelLabel"
2248
2251
  ),
2249
- "aria-describedby": Ot ? rs : void 0,
2252
+ "aria-describedby": At ? cs : void 0,
2250
2253
  onValueChange: (e) => {
2251
- if (Ds.some(
2254
+ if ($s.some(
2252
2255
  (s) => s.value === e && !s.disabled
2253
2256
  )) {
2254
- if (Le && e === "on-device" && !Re) {
2255
- pi();
2257
+ if (Me && e === "on-device" && !Ne) {
2258
+ Ri();
2256
2259
  return;
2257
2260
  }
2258
- if (N) {
2259
- Oe(
2260
- A,
2261
+ if (x) {
2262
+ Te(
2263
+ D,
2261
2264
  e,
2262
- q,
2265
+ C,
2263
2266
  "operator"
2264
2267
  );
2265
2268
  return;
2266
2269
  }
2267
- be(e), oe(null);
2270
+ Re(e), le(null);
2268
2271
  }
2269
2272
  }
2270
2273
  }
2271
2274
  ),
2272
- Tt
2275
+ Pt
2273
2276
  ]
2274
2277
  }
2275
2278
  ),
2276
- Ot && !$e ? /* @__PURE__ */ n("span", { id: rs, className: "ds:sr-only", children: Ot }) : null
2279
+ At && !Fe ? /* @__PURE__ */ n("span", { id: cs, className: "ds:sr-only", children: At }) : null
2277
2280
  ] })
2278
2281
  ]
2279
2282
  }
2280
2283
  ) : null,
2281
- K || Tn ? /* @__PURE__ */ n("span", { role: "status", className: "ds:sr-only", children: Cs ? r("signatureRequest.operatorChannelReverted", {
2282
- channel: V[Cs].label
2283
- }) : oi }) : null,
2284
- (K || f) && Tn ? /* @__PURE__ */ n(pa, { decorative: !0 }) : null,
2285
- Tn ? /* @__PURE__ */ u(
2284
+ X || Pn ? /* @__PURE__ */ n("span", { role: "status", className: "ds:sr-only", children: Is ? r("signatureRequest.operatorChannelReverted", {
2285
+ channel: V[Is].label
2286
+ }) : hi }) : null,
2287
+ (X || f) && Pn ? /* @__PURE__ */ n(Ra, { decorative: !0 }) : null,
2288
+ Pn ? /* @__PURE__ */ u(
2286
2289
  "section",
2287
2290
  {
2288
- className: `${pn} ds:flex ds:flex-col ds:gap-[var(--spacing-sm)] ds:text-start`,
2291
+ className: `${Rn} ds:flex ds:flex-col ds:gap-[var(--spacing-sm)] ds:text-start`,
2289
2292
  children: [
2290
- /* @__PURE__ */ u("div", { className: ae, children: [
2291
- /* @__PURE__ */ u("div", { className: _n, children: [
2293
+ /* @__PURE__ */ u("div", { className: se, children: [
2294
+ /* @__PURE__ */ u("div", { className: zn, children: [
2292
2295
  /* @__PURE__ */ n("p", { className: "type-eyebrow ds:text-[color:var(--muted-foreground)]", children: r("signatureRequest.signersSection") }),
2293
- Ge === "addRow" ? /* @__PURE__ */ n(
2296
+ Ke === "addRow" ? /* @__PURE__ */ n(
2294
2297
  L,
2295
2298
  {
2296
- ref: bn,
2299
+ ref: qn,
2297
2300
  intent: "outline",
2298
2301
  size: "sm",
2299
- startIcon: /* @__PURE__ */ n(et, {}),
2300
- disabled: !fi,
2301
- "aria-describedby": At ? is : void 0,
2302
- onClick: xi,
2302
+ startIcon: /* @__PURE__ */ n(at, {}),
2303
+ disabled: !Ni,
2304
+ "aria-describedby": Xn ? gt : void 0,
2305
+ onClick: Ii,
2303
2306
  children: r("signatureRequest.addSigner")
2304
2307
  }
2305
- ) : Ge !== null ? (
2308
+ ) : Ke !== null ? (
2306
2309
  // The second signee line, or the host's own
2307
2310
  // create-signee page, as platform's "Aggiungi
2308
2311
  // firmatario".
2309
2312
  /* @__PURE__ */ n(
2310
2313
  L,
2311
2314
  {
2312
- ref: bn,
2315
+ ref: qn,
2313
2316
  intent: "outline",
2314
2317
  size: "sm",
2315
- startIcon: Ge === "openSlot" ? /* @__PURE__ */ n(et, {}) : /* @__PURE__ */ n(Xt, {}),
2318
+ startIcon: Ke === "openSlot" ? /* @__PURE__ */ n(at, {}) : /* @__PURE__ */ n(es, {}),
2316
2319
  disabled: y,
2317
- "data-action": Ge === "openSlot" ? "add-second-signee" : "create-signee",
2318
- onClick: Ge === "openSlot" ? qi : le,
2320
+ "data-action": Ke === "openSlot" ? "add-second-signee" : "create-signee",
2321
+ onClick: Ke === "openSlot" ? yi : re,
2319
2322
  children: r(
2320
- Ge === "openSlot" ? "signatureRequest.addSigner" : "signatureRequest.addSignatory"
2323
+ Ke === "openSlot" ? "signatureRequest.addSigner" : "signatureRequest.addSignatory"
2321
2324
  )
2322
2325
  }
2323
2326
  )
2324
2327
  ) : null
2325
2328
  ] }),
2326
- En ? /* @__PURE__ */ u(
2327
- U,
2329
+ Ln ? /* @__PURE__ */ u(
2330
+ j,
2328
2331
  {
2329
2332
  variant: "warning",
2330
2333
  announce: "polite",
2331
2334
  "data-note": "minor-patient",
2332
- "data-warning": En,
2333
- className: F,
2335
+ "data-warning": Ln,
2336
+ className: H,
2334
2337
  children: [
2335
- /* @__PURE__ */ n(U.Description, { children: r(Cr[En]) }),
2336
- $t ? /* @__PURE__ */ n(U.Action, { children: /* @__PURE__ */ n(
2338
+ /* @__PURE__ */ n(j.Description, { children: r(wr[Ln]) }),
2339
+ Bt ? /* @__PURE__ */ n(j.Action, { children: /* @__PURE__ */ n(
2337
2340
  L,
2338
2341
  {
2339
2342
  intent: "tonal",
2340
2343
  size: "sm",
2341
- startIcon: /* @__PURE__ */ n(et, {}),
2344
+ startIcon: /* @__PURE__ */ n(at, {}),
2342
2345
  disabled: y,
2343
- onClick: le,
2346
+ onClick: re,
2344
2347
  children: r("signatureRequest.addSignatory")
2345
2348
  }
2346
2349
  ) }) : null
2347
2350
  ]
2348
2351
  }
2349
2352
  ) : null,
2350
- Bs ? /* @__PURE__ */ n("div", { className: F, children: /* @__PURE__ */ n(
2353
+ Gs ? /* @__PURE__ */ n("div", { className: H, children: /* @__PURE__ */ n(
2351
2354
  L,
2352
2355
  {
2353
2356
  intent: "link",
2354
2357
  size: "sm",
2355
- startIcon: /* @__PURE__ */ n(et, {}),
2358
+ startIcon: /* @__PURE__ */ n(at, {}),
2356
2359
  disabled: y,
2357
- onClick: le,
2360
+ onClick: re,
2358
2361
  children: r("signatureRequest.addSignatory")
2359
2362
  }
2360
2363
  ) }) : null,
2361
- v && !Rn ? /* @__PURE__ */ u(
2364
+ v && !Cn ? /* @__PURE__ */ u(
2362
2365
  "div",
2363
2366
  {
2364
- className: `${F} ds:flex ds:flex-col ds:gap-[var(--spacing-xs)]`,
2367
+ className: `${H} ds:flex ds:flex-col ds:gap-[var(--spacing-xs)]`,
2365
2368
  children: [
2366
2369
  /* @__PURE__ */ n(
2367
2370
  "label",
2368
2371
  {
2369
- htmlFor: Ta,
2372
+ htmlFor: Pa,
2370
2373
  className: "type-label ds:text-foreground",
2371
2374
  children: r("signatureRequest.channelLabel")
2372
2375
  }
2373
2376
  ),
2374
- sa
2377
+ la
2375
2378
  ]
2376
2379
  }
2377
2380
  ) : null,
2378
- Rn ? null : aa,
2379
- $s ? /* @__PURE__ */ n(
2381
+ Cn ? null : oa,
2382
+ Bs ? /* @__PURE__ */ n(
2380
2383
  "p",
2381
2384
  {
2382
- id: Qa,
2385
+ id: Ja,
2383
2386
  "data-note": "second-signee-hint",
2384
- className: `${F} type-body-sm ds:text-[color:var(--muted-foreground)]`,
2385
- children: $s
2387
+ className: `${H} type-body-sm ds:text-[color:var(--muted-foreground)]`,
2388
+ children: Bs
2386
2389
  }
2387
2390
  ) : null,
2388
- At ? /* @__PURE__ */ n(
2391
+ Xn ? /* @__PURE__ */ n(
2389
2392
  "p",
2390
2393
  {
2391
- id: is,
2392
- className: `${F} type-body-sm ds:text-[color:var(--muted-foreground)]`,
2393
- children: At
2394
+ id: gt,
2395
+ "data-note": "second-signee-hint",
2396
+ className: `${H} type-body-sm ds:text-[color:var(--muted-foreground)]`,
2397
+ children: Xn
2394
2398
  }
2395
2399
  ) : null
2396
2400
  ] }),
2397
- /* @__PURE__ */ u("div", { className: nr, children: [
2398
- x.map((e, t) => {
2399
- var ma;
2401
+ /* @__PURE__ */ u("div", { className: ir, children: [
2402
+ N.map((e, t) => {
2403
+ var va;
2400
2404
  const s = l.filter(
2401
- (D) => D.value === e.signerId || !Et.includes(D.value)
2402
- ), a = Fe(
2405
+ (P) => P.value === e.signerId || !Lt.includes(P.value)
2406
+ ), a = Ae(
2403
2407
  l,
2404
2408
  e.signerId
2405
2409
  ), c = l.find(
2406
- (D) => D.value === e.signerId
2410
+ (P) => P.value === e.signerId
2407
2411
  ), d = (c == null ? void 0 : c.isMinor) === !0 && c.isPatient !== !0, h = (f || G) && t > 0, g = h ? s.filter(
2408
- (D) => D.isPatient !== !0
2412
+ (P) => P.isPatient !== !0
2409
2413
  ) : s, T = g.some(
2410
- (D) => D.value === e.signerId
2411
- ), w = h ? Vn : null, P = `${cs}-${e.rowId}`, Ce = `${Va}-${e.rowId}`, J = Cn(
2414
+ (P) => P.value === e.signerId
2415
+ ), I = h ? Yn : null, A = `${hs}-${e.rowId}`, xe = `${Ya}-${e.rowId}`, Q = wn(
2412
2416
  e.signerId
2413
- ), he = mt(
2417
+ ), he = vt(
2414
2418
  e.signerId,
2415
- (ma = Y == null ? void 0 : Y.signerAvailableChannels) == null ? void 0 : ma[e.signerId]
2416
- ), Ee = Vs(
2419
+ (va = J == null ? void 0 : J.signerAvailableChannels) == null ? void 0 : va[e.signerId]
2420
+ ), Se = Ys(
2417
2421
  he,
2418
- J
2419
- ), Ne = !v && Ee.every(
2420
- (D) => D.disabled
2421
- ), xe = v ? void 0 : Qs(
2422
+ Q
2423
+ ), qe = !v && Se.every(
2424
+ (P) => P.disabled
2425
+ ), Ce = v ? void 0 : Js(
2422
2426
  he,
2423
- J,
2424
- Ne
2425
- ), He = `${Ga}-${e.rowId}`, ua = _t(t) && cn, Ti = f || G ? h : x.length > 1, Ei = (D) => {
2426
- if (D === Qt) {
2427
- Hs && (le == null || le());
2427
+ Q,
2428
+ qe
2429
+ ), Be = `${Xa}-${e.rowId}`, pa = Ft(t) && mn, Pi = f || G ? h : N.length > 1, Li = (P) => {
2430
+ if (P === Jt) {
2431
+ Us && (re == null || re());
2428
2432
  return;
2429
2433
  }
2430
- if (!D || !g.some(
2431
- (se) => se.value === D
2434
+ if (!P || !g.some(
2435
+ (me) => me.value === P
2432
2436
  ))
2433
2437
  return;
2434
- if (G && !h && yn(!1), v) {
2435
- ze(
2436
- q.map(
2437
- (se) => se.rowId === e.rowId ? { ...se, signerId: D } : se
2438
+ if (G && !h && Ve(!1), v) {
2439
+ He(
2440
+ C.map(
2441
+ (me) => me.rowId === e.rowId ? { ...me, signerId: P } : me
2438
2442
  ),
2439
2443
  S,
2440
2444
  {
@@ -2445,62 +2449,71 @@ const wr = Di(
2445
2449
  );
2446
2450
  return;
2447
2451
  }
2448
- const Ut = qn(
2449
- D,
2452
+ const Vt = yn(
2453
+ P,
2450
2454
  e.channel
2451
- ), Pn = (f || G) && !h && q.length > 1, Ln = (Pn ? q.slice(0, 1) : q).map(
2452
- (se) => se.rowId === e.rowId ? {
2453
- ...se,
2454
- signerId: D,
2455
- channel: Ut,
2456
- skipOtp: Ut === "on-device" ? se.skipOtp : void 0
2457
- } : se
2458
- ), hn = Pn && x.length > 1 ? [r("signatureRequest.secondSigneeCleared")] : [];
2459
- if (N) {
2460
- Oe(
2461
- A,
2462
- H,
2463
- Ln,
2455
+ ), $n = (f || G) && !h && C.length > 1, De = ($n ? C.slice(0, 1) : C).map(
2456
+ (me) => me.rowId === e.rowId ? {
2457
+ ...me,
2458
+ signerId: P,
2459
+ channel: Vt,
2460
+ skipOtp: Vt === "on-device" ? me.skipOtp : void 0
2461
+ } : me
2462
+ ), Ze = $n && N.length > 1 ? [r("signatureRequest.secondSigneeCleared")] : [];
2463
+ if (x) {
2464
+ Te(
2465
+ D,
2466
+ F,
2467
+ De,
2464
2468
  "signers",
2465
- hn
2469
+ Ze
2466
2470
  );
2467
2471
  return;
2468
2472
  }
2469
- ve(Ln), hn.length > 0 && (oe(null), Me(hn.join(" ")));
2470
- }, Ai = (D) => {
2471
- if (!Ee.some(
2472
- (mn) => mn.value === D && !mn.disabled
2473
+ be(De), Ze.length > 0 && (le(null), ze(Ze.join(" ")));
2474
+ }, _i = (P) => {
2475
+ if (!Se.some(
2476
+ (vn) => vn.value === P && !vn.disabled
2473
2477
  )) return;
2474
- const Pn = D, Ln = q.map(
2475
- (mn) => mn.rowId === e.rowId ? { ...mn, channel: Pn, skipOtp: void 0 } : mn
2476
- ), hn = f && !h && x.length > 1 ? st({
2478
+ const $n = P, De = C.map(
2479
+ (vn) => vn.rowId === e.rowId ? { ...vn, channel: $n, skipOtp: void 0 } : vn
2480
+ ), Ze = f && !h ? lt({
2477
2481
  items: te,
2478
- channel: Pn,
2479
- primaryIsPatient: On
2480
- }) : null, se = hn === null ? [] : [r(Kt[hn])];
2481
- if (N) {
2482
- Oe(
2483
- A,
2484
- H,
2485
- Ln,
2482
+ channel: $n,
2483
+ primaryIsPatient: Dn
2484
+ }) : null;
2485
+ Ze !== null && Ve(!1);
2486
+ const me = !h && As(
2487
+ De,
2488
+ ln(De, S)
2489
+ ), fn = [];
2490
+ if (Ze !== null && N.length > 1 && fn.push(r(Zt[Ze])), me && De[1] && fn.push(
2491
+ Ps(De[1].signerId)
2492
+ ), x) {
2493
+ Te(
2494
+ D,
2495
+ F,
2496
+ De,
2486
2497
  "signers",
2487
- se
2498
+ fn
2488
2499
  );
2489
2500
  return;
2490
2501
  }
2491
- ve(Ln), se.length > 0 && (oe(null), Me(se.join(" ")));
2492
- }, ha = /* @__PURE__ */ u(
2502
+ be(De), fn.length > 0 && le(null), ze(
2503
+ fn.length > 0 ? fn.join(" ") : null
2504
+ );
2505
+ }, fa = /* @__PURE__ */ u(
2493
2506
  "div",
2494
2507
  {
2495
2508
  role: "group",
2496
2509
  "aria-label": h ? void 0 : a,
2497
- "aria-labelledby": h ? Ce : void 0,
2510
+ "aria-labelledby": h ? xe : void 0,
2498
2511
  "data-signer-id": e.signerId,
2499
2512
  "data-signer-role": f || G ? h ? "second" : "main" : void 0,
2500
- className: ae,
2513
+ className: se,
2501
2514
  children: [
2502
- /* @__PURE__ */ n("div", { className: nt, children: /* @__PURE__ */ n(
2503
- Zn,
2515
+ /* @__PURE__ */ n("div", { className: it, children: /* @__PURE__ */ n(
2516
+ st,
2504
2517
  {
2505
2518
  "aria-hidden": "true",
2506
2519
  name: f && !T ? void 0 : a,
@@ -2510,16 +2523,16 @@ const wr = Di(
2510
2523
  /* @__PURE__ */ n(
2511
2524
  "div",
2512
2525
  {
2513
- className: v && !Rn ? jt : Na,
2526
+ className: v && !Cn ? Kt : Sa,
2514
2527
  children: /* @__PURE__ */ n(
2515
2528
  Ue,
2516
2529
  {
2517
- ref: h ? ns : void 0,
2518
- options: Fs(g),
2530
+ ref: h ? is : void 0,
2531
+ options: Ws(g),
2519
2532
  value: f && !T ? "" : e.signerId,
2520
- tone: w ? "error" : "default",
2521
- "aria-describedby": w ? P : void 0,
2522
- onValueChange: Ei,
2533
+ tone: I ? "error" : "default",
2534
+ "aria-describedby": I ? A : t === 0 ? _t("patient") : void 0,
2535
+ onValueChange: Li,
2523
2536
  required: !0,
2524
2537
  disabled: y,
2525
2538
  placeholder: r(
@@ -2532,8 +2545,8 @@ const wr = Di(
2532
2545
  )
2533
2546
  }
2534
2547
  ),
2535
- Rn ? /* @__PURE__ */ u("div", { className: tt, children: [
2536
- t === 0 ? sa : /* @__PURE__ */ u(
2548
+ Cn ? /* @__PURE__ */ u("div", { className: rt, children: [
2549
+ t === 0 ? la : /* @__PURE__ */ u(
2537
2550
  "span",
2538
2551
  {
2539
2552
  "data-note": "batch-channel",
@@ -2552,97 +2565,100 @@ const wr = Di(
2552
2565
  ]
2553
2566
  }
2554
2567
  ),
2555
- Tt
2568
+ Pt
2556
2569
  ] }) : null,
2557
- v ? null : /* @__PURE__ */ u("div", { className: tt, children: [
2570
+ v ? null : /* @__PURE__ */ u("div", { className: rt, children: [
2558
2571
  /* @__PURE__ */ n(
2559
2572
  Ue,
2560
2573
  {
2561
2574
  id: `signature-request-signer-channel-${e.rowId}`,
2562
- options: Ee,
2563
- value: Ne ? "" : e.channel,
2575
+ options: Se,
2576
+ value: qe ? "" : e.channel,
2564
2577
  adornmentInTrigger: !0,
2565
2578
  showDescriptions: !0,
2566
2579
  disabled: y,
2567
2580
  "aria-label": r(
2568
2581
  "signatureRequest.channelLabel"
2569
2582
  ),
2570
- "aria-describedby": xe ? He : void 0,
2571
- onValueChange: Ai
2583
+ "aria-describedby": [
2584
+ Ce ? Be : null,
2585
+ t === 0 ? _t("channel") : null
2586
+ ].filter(Boolean).join(" ") || void 0,
2587
+ onValueChange: _i
2572
2588
  }
2573
2589
  ),
2574
- Tt
2590
+ Pt
2575
2591
  ] }),
2576
- xe && !Ne ? /* @__PURE__ */ n(
2592
+ Ce && !qe ? /* @__PURE__ */ n(
2577
2593
  "span",
2578
2594
  {
2579
- id: He,
2595
+ id: Be,
2580
2596
  className: "ds:sr-only",
2581
- children: xe
2597
+ children: Ce
2582
2598
  }
2583
2599
  ) : null,
2584
- Ti ? /* @__PURE__ */ n("div", { className: xa, children: /* @__PURE__ */ n(
2585
- vn,
2600
+ Pi ? /* @__PURE__ */ n("div", { className: Ia, children: /* @__PURE__ */ n(
2601
+ xn,
2586
2602
  {
2587
2603
  intent: "ghost",
2588
2604
  size: "sm",
2589
- icon: /* @__PURE__ */ n(Ra, {}),
2605
+ icon: /* @__PURE__ */ n(Ca, {}),
2590
2606
  disabled: y,
2591
2607
  "aria-label": r(
2592
2608
  "signatureRequest.removeSigner"
2593
2609
  ),
2594
- onClick: () => wi(e.rowId)
2610
+ onClick: () => Oi(e.rowId)
2595
2611
  }
2596
2612
  ) }) : null,
2597
2613
  d ? /* @__PURE__ */ n(
2598
- U,
2614
+ j,
2599
2615
  {
2600
2616
  variant: "warning",
2601
2617
  announce: "polite",
2602
2618
  "data-note": "minor-signer",
2603
- className: F,
2604
- children: /* @__PURE__ */ n(U.Description, { children: r("signatureRequest.minorSignerWarning") })
2619
+ className: H,
2620
+ children: /* @__PURE__ */ n(j.Description, { children: r("signatureRequest.minorSignerWarning") })
2605
2621
  }
2606
2622
  ) : null,
2607
- w ? /* @__PURE__ */ n(
2623
+ I ? /* @__PURE__ */ n(
2608
2624
  "p",
2609
2625
  {
2610
- id: P,
2626
+ id: A,
2611
2627
  role: "status",
2612
2628
  "data-note": "second-signee-issue",
2613
- "data-issue": w,
2614
- className: `${F} type-body-sm ds:text-[color:var(--destructive)]`,
2615
- children: r(qr[w])
2629
+ "data-issue": I,
2630
+ className: `${H} type-body-sm ds:text-[color:var(--destructive)]`,
2631
+ children: r(yr[I])
2616
2632
  }
2617
2633
  ) : null,
2618
- Ne && xe ? /* @__PURE__ */ n(
2634
+ qe && Ce ? /* @__PURE__ */ n(
2619
2635
  "p",
2620
2636
  {
2621
- id: He,
2637
+ id: Be,
2622
2638
  "data-note": "no-channel",
2623
- className: `${F} type-body-sm ds:text-[color:var(--muted-foreground)]`,
2624
- children: xe
2639
+ className: `${H} type-body-sm ds:text-[color:var(--muted-foreground)]`,
2640
+ children: Ce
2625
2641
  }
2626
2642
  ) : null,
2627
- v ? null : Xs(
2628
- ds(
2643
+ v ? null : ea(
2644
+ ms(
2629
2645
  e.signerId,
2630
2646
  he
2631
2647
  )
2632
2648
  ),
2633
- !v && e.channel === "on-device" && !Ne ? /* @__PURE__ */ n("div", { className: F, children: /* @__PURE__ */ n(
2634
- ga,
2649
+ !v && e.channel === "on-device" && !qe ? /* @__PURE__ */ n("div", { className: H, children: /* @__PURE__ */ n(
2650
+ ba,
2635
2651
  {
2636
2652
  label: r("signatureRequest.noOtp"),
2637
- checked: Mt(e, t),
2638
- disabled: y || ua,
2639
- "aria-describedby": ua ? $n : void 0,
2640
- onCheckedChange: (D) => Ni(e.rowId, {
2641
- skipOtp: D
2653
+ checked: Ht(e, t),
2654
+ disabled: y || pa,
2655
+ "aria-describedby": pa ? Bn : void 0,
2656
+ onCheckedChange: (P) => Si(e.rowId, {
2657
+ skipOtp: P
2642
2658
  })
2643
2659
  }
2644
2660
  ) }) : null,
2645
- Rn && t === 0 ? aa : null
2661
+ Cn && t === 0 ? oa : null
2646
2662
  ]
2647
2663
  },
2648
2664
  e.rowId
@@ -2652,31 +2668,31 @@ const wr = Di(
2652
2668
  {
2653
2669
  className: "ds:flex ds:flex-col ds:gap-[var(--spacing-xs)]",
2654
2670
  children: [
2655
- /* @__PURE__ */ n("div", { className: ae, children: /* @__PURE__ */ n(
2671
+ /* @__PURE__ */ n("div", { className: se, children: /* @__PURE__ */ n(
2656
2672
  "p",
2657
2673
  {
2658
- id: Ce,
2659
- className: `${F} type-label ds:text-[color:var(--muted-foreground)]`,
2674
+ id: xe,
2675
+ className: `${H} type-label ds:text-[color:var(--muted-foreground)]`,
2660
2676
  children: r("signatureRequest.secondSigneeLabel")
2661
2677
  }
2662
2678
  ) }),
2663
- ha
2679
+ fa
2664
2680
  ]
2665
2681
  },
2666
2682
  e.rowId
2667
- ) : ha;
2683
+ ) : fa;
2668
2684
  }),
2669
- Ms ? /* @__PURE__ */ u(
2685
+ Hs ? /* @__PURE__ */ u(
2670
2686
  "div",
2671
2687
  {
2672
2688
  "data-second-signee-slot": "",
2673
2689
  className: "ds:flex ds:flex-col ds:gap-[var(--spacing-xs)]",
2674
2690
  children: [
2675
- /* @__PURE__ */ n("div", { className: ae, children: /* @__PURE__ */ n(
2691
+ /* @__PURE__ */ n("div", { className: se, children: /* @__PURE__ */ n(
2676
2692
  "p",
2677
2693
  {
2678
- id: os,
2679
- className: `${F} type-label ds:text-[color:var(--muted-foreground)]`,
2694
+ id: us,
2695
+ className: `${H} type-label ds:text-[color:var(--muted-foreground)]`,
2680
2696
  children: r("signatureRequest.secondSigneeLabel")
2681
2697
  }
2682
2698
  ) }),
@@ -2684,22 +2700,22 @@ const wr = Di(
2684
2700
  "div",
2685
2701
  {
2686
2702
  role: "group",
2687
- "aria-labelledby": os,
2688
- className: ae,
2703
+ "aria-labelledby": us,
2704
+ className: se,
2689
2705
  children: [
2690
- /* @__PURE__ */ n("div", { className: nt, children: /* @__PURE__ */ n(Zn, { "aria-hidden": "true", size: "sm" }) }),
2691
- /* @__PURE__ */ n("div", { className: jt, children: /* @__PURE__ */ n(
2706
+ /* @__PURE__ */ n("div", { className: it, children: /* @__PURE__ */ n(st, { "aria-hidden": "true", size: "sm" }) }),
2707
+ /* @__PURE__ */ n("div", { className: Kt, children: /* @__PURE__ */ n(
2692
2708
  Ue,
2693
2709
  {
2694
- ref: es,
2695
- options: Fs(Dt),
2710
+ ref: as,
2711
+ options: Ws(Mt),
2696
2712
  value: "",
2697
2713
  onValueChange: (e) => {
2698
- if (e === Qt) {
2699
- le == null || le();
2714
+ if (e === Jt) {
2715
+ re == null || re();
2700
2716
  return;
2701
2717
  }
2702
- Ci(e);
2718
+ wi(e);
2703
2719
  },
2704
2720
  disabled: y,
2705
2721
  placeholder: r(
@@ -2710,17 +2726,17 @@ const wr = Di(
2710
2726
  )
2711
2727
  }
2712
2728
  ) }),
2713
- /* @__PURE__ */ n("div", { className: xa, children: /* @__PURE__ */ n(
2714
- vn,
2729
+ /* @__PURE__ */ n("div", { className: Ia, children: /* @__PURE__ */ n(
2730
+ xn,
2715
2731
  {
2716
2732
  intent: "ghost",
2717
2733
  size: "sm",
2718
- icon: /* @__PURE__ */ n(Ra, {}),
2734
+ icon: /* @__PURE__ */ n(Ca, {}),
2719
2735
  disabled: y,
2720
2736
  "aria-label": r(
2721
2737
  "signatureRequest.removeSigner"
2722
2738
  ),
2723
- onClick: Si
2739
+ onClick: ki
2724
2740
  }
2725
2741
  ) })
2726
2742
  ]
@@ -2733,33 +2749,33 @@ const wr = Di(
2733
2749
  ]
2734
2750
  }
2735
2751
  ) : null,
2736
- Gs || ie ? /* @__PURE__ */ n("div", { className: pn, children: /* @__PURE__ */ u("div", { className: ae, children: [
2737
- Gs ? /* @__PURE__ */ n(
2738
- U,
2752
+ Xs || ae ? /* @__PURE__ */ n("div", { className: Rn, children: /* @__PURE__ */ u("div", { className: se, children: [
2753
+ Xs ? /* @__PURE__ */ n(
2754
+ j,
2739
2755
  {
2740
2756
  variant: "warning",
2741
- id: $n,
2742
- className: F,
2743
- children: /* @__PURE__ */ n(U.Description, { children: r("signatureRequest.noOtpWarning") })
2757
+ id: Bn,
2758
+ className: H,
2759
+ children: /* @__PURE__ */ n(j.Description, { children: r("signatureRequest.noOtpWarning") })
2744
2760
  }
2745
2761
  ) : null,
2746
- ie ? /* @__PURE__ */ n(U, { variant: "error", className: F, children: /* @__PURE__ */ n(U.Description, { children: ie }) }) : null
2762
+ ae ? /* @__PURE__ */ n(j, { variant: "error", className: H, children: /* @__PURE__ */ n(j.Description, { children: ae }) }) : null
2747
2763
  ] }) }) : null
2748
2764
  ] }),
2749
- /* @__PURE__ */ u(C.Footer, { children: [
2765
+ /* @__PURE__ */ u(q.Footer, { children: [
2750
2766
  /* @__PURE__ */ n(
2751
2767
  L,
2752
2768
  {
2753
2769
  intent: "primary",
2754
- startIcon: /* @__PURE__ */ n(ba, {}),
2755
- onClick: yi,
2756
- "aria-describedby": Vn !== null && x[1] ? `${cs}-${x[1].rowId}` : void 0,
2757
- disabled: !y && (ue && x.length === 0 || Ws || Vn !== null || !ue && !K || f && (ge || te.length === 0)),
2770
+ startIcon: /* @__PURE__ */ n(qa, {}),
2771
+ onClick: Ei,
2772
+ "aria-describedby": Yn !== null && N[1] ? `${hs}-${N[1].rowId}` : void 0,
2773
+ disabled: !y && (ue && N.length === 0 || Qs || Yn !== null || !ue && !X || f && (de || te.length === 0)),
2758
2774
  loading: y,
2759
2775
  children: r("signatureRequest.requestSignature")
2760
2776
  }
2761
2777
  ),
2762
- /* @__PURE__ */ n(C.Close, { asChild: !0, children: /* @__PURE__ */ n(L, { intent: "outline", disabled: y, children: r("signatureRequest.close") }) })
2778
+ /* @__PURE__ */ n(q.Close, { asChild: !0, children: /* @__PURE__ */ n(L, { intent: "outline", disabled: y, children: r("signatureRequest.close") }) })
2763
2779
  ] })
2764
2780
  ] })
2765
2781
  ]
@@ -2767,8 +2783,8 @@ const wr = Di(
2767
2783
  ) }) }) });
2768
2784
  }
2769
2785
  );
2770
- wr.displayName = "SignatureRequestModal";
2786
+ Or.displayName = "SignatureRequestModal";
2771
2787
  export {
2772
- wr as S
2788
+ Or as S
2773
2789
  };
2774
- //# sourceMappingURL=signature-request-DtLph5Z4.js.map
2790
+ //# sourceMappingURL=signature-request-opW0fQ5P.js.map