@incodetech/web 0.0.0-dev-20260403-eccc51c → 0.0.0-dev-20260407-4580f1c
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/AsYouType-DPWqJvFu.js +2482 -0
- package/dist/addressAutocomplete-B3f6PGTT.js +108 -0
- package/dist/aligndevicelottie-C9xl1spu.js +12757 -0
- package/dist/antifraud/antifraud.es.js +17 -18
- package/dist/antifraud/styles.css +1 -1
- package/dist/authentication/authentication.es.js +28 -50
- package/dist/back-horizontal-hint-Be3dUGk6.js +137 -0
- package/dist/back-tutorial-BNTyW-1N.js +14584 -0
- package/dist/back-vertical-hint-Bz_rnhd-.js +128 -0
- package/dist/backdevicelottie-DBB1YCtW.js +16678 -0
- package/dist/base.css +327 -67
- package/dist/blurdevicelottie-9WvZCZ6C.js +15939 -0
- package/dist/browser-ponyfill-B4Qc6yfW.js +299 -0
- package/dist/button-DhL5eRT3.js +123 -0
- package/dist/checkbox-l8NxPf4o.js +85 -0
- package/dist/consent/consent.es.js +82 -89
- package/dist/consent/styles.css +1 -1
- package/dist/countries-y2ydYDhN.js +8323 -0
- package/dist/curp-validation/curp-validation.es.js +271 -313
- package/dist/curp-validation/styles.css +1 -1
- package/dist/dateInputComposed-B9WqdYx9.js +2 -0
- package/dist/dateInputComposed-ndsGHX1M.js +94 -0
- package/dist/defineProperty-brqHEHA_.js +39 -0
- package/dist/document-capture/styles.css +1 -1
- package/dist/documentCapture-wDgRLdon.js +784 -0
- package/dist/dropdownComposed-_Ey7wJNG.js +258 -0
- package/dist/ekyb/ekyb.es.js +2 -0
- package/dist/ekyb/styles.css +1 -1
- package/dist/ekybModule-BBOm1y49.js +2 -0
- package/dist/ekybModule-fz6i9ZRt.js +286 -0
- package/dist/ekyc/ekyc.es.js +2 -0
- package/dist/ekyc/styles.css +1 -1
- package/dist/ekycModule-SeTFG3AJ.js +233 -0
- package/dist/ekycModule-hxIcNX8n.js +2 -0
- package/dist/email/email.es.js +110 -154
- package/dist/email/styles.css +1 -1
- package/dist/extensibility-DJihqIzM.js +2248 -0
- package/dist/extensibility.es.js +22 -150
- package/dist/face-match/styles.css +147 -73
- package/dist/faceMatch-DH8sLx34.js +191 -0
- package/dist/flip-animation-DOJzdXB-.js +6983 -0
- package/dist/flow/flow.es.js +2273 -2613
- package/dist/flow/styles.css +432 -73
- package/dist/formField-BRTbY8w9.js +100 -0
- package/dist/front-horizontal-hint-aGAhadA2.js +380 -0
- package/dist/front-vertical-hint-DZz1VeNp.js +420 -0
- package/dist/frontdevicelottie-DadDp6be.js +17302 -0
- package/dist/geolocation/geolocation.es.js +852 -832
- package/dist/geolocation/styles.css +1 -1
- package/dist/glaredevicelottie-BfI84cPw.js +14466 -0
- package/dist/governmentValidation/governmentValidation.es.js +100 -106
- package/dist/governmentValidation/styles.css +1 -1
- package/dist/i18n-DZOHbK9q.js +1916 -0
- package/dist/icons-BHbofCgJ.js +245 -0
- package/dist/id/id.es.js +53 -59
- package/dist/id/styles.css +1 -1
- package/dist/id-laser-h-BWyU3VgL.js +467 -0
- package/dist/id-laser-v-JiWXUlv0.js +467 -0
- package/dist/id-tutorial-Cc9xg5_J.js +13152 -0
- package/dist/incodeModule-Bf6yJ8RB.js +18 -0
- package/dist/index.es.js +4 -25
- package/dist/inputComposed-BhbfD8Ru.js +77 -0
- package/dist/loadingIcon-CeQt7Zgb.js +146 -0
- package/dist/mandatoryConsent-LBS8E0rj.js +101 -0
- package/dist/numberedStep-CQVRixRP.js +11 -0
- package/dist/otpInput-CDIG9el7.js +143 -0
- package/dist/page-SvlJWUfz.js +61 -0
- package/dist/passport-horizontal-hint-CFsGs7Dp.js +293 -0
- package/dist/passport-tutorial-z0LN7Hsp.js +11688 -0
- package/dist/passport-vertical-hint-BnCpKWeN.js +267 -0
- package/dist/phone/phone.es.js +87 -121
- package/dist/phone/styles.css +1 -1
- package/dist/phoneInput-C9T_8FJt.js +138 -0
- package/dist/phoneInputComposed-B-0zieIW.js +407 -0
- package/dist/processing-B5zhNH6I.js +15 -0
- package/dist/redirect-to-mobile/styles.css +1 -1
- package/dist/richText-Db0PfpkE.js +1973 -0
- package/dist/rolldown-runtime-CjdbFOpI.js +13 -0
- package/dist/selfie/selfie.es.js +29 -50
- package/dist/selfie/styles.css +170 -66
- package/dist/selfieTutorial-B0MIyPrk.js +2676 -0
- package/dist/setup-Dq2bzNKH.js +15 -0
- package/dist/signature/signature.es.js +557 -707
- package/dist/signature/styles.css +1 -1
- package/dist/spacer-DCljE53A.js +59 -0
- package/dist/spinner-Bk0YuoLu.js +1 -0
- package/dist/spinner-snIGzmm8.js +41 -0
- package/dist/successIcon-AHrfmJvv.js +17 -0
- package/dist/tutorial-DNOd11tg.js +2780 -0
- package/dist/types/ekyb.d.ts +29 -0
- package/dist/types/ekyc.d.ts +29 -0
- package/dist/types/index.d.ts +0 -8
- package/dist/typography-BNbFNFek.js +1 -0
- package/dist/typography-DvHeVWfY.js +29 -0
- package/dist/uiConfig-CwpQ-IM6.js +20 -0
- package/dist/vendor-preact-D6SntenC.js +958 -0
- package/dist/warningIcon-Cvj-ayg1.js +17 -0
- package/package.json +8 -11
- package/dist/AsYouType-D1H_js4X.js +0 -2607
- package/dist/Trans-aTzdT_SA.js +0 -55
- package/dist/addressAutocomplete-C8-wL1j_.js +0 -153
- package/dist/aligndevicelottie-DlQCRPfM.js +0 -29
- package/dist/back-horizontal-hint-CSlf9KI1.js +0 -5
- package/dist/back-tutorial-An9AcMSe.js +0 -29
- package/dist/back-vertical-hint-CNieqiCr.js +0 -5
- package/dist/backdevicelottie-B4NgyWmX.js +0 -29
- package/dist/blurdevicelottie-_BZRug1c.js +0 -29
- package/dist/browser-ponyfill-B6W6hHVY.js +0 -344
- package/dist/button-CE9kRlem.js +0 -184
- package/dist/cameraView-C2X7klNb.js +0 -55
- package/dist/captureOverlay-tCb4R4WE.js +0 -592
- package/dist/checkbox-B5X-mfqq.js +0 -137
- package/dist/chevronDown-DSHaPKbi.js +0 -23
- package/dist/closeIcon-9Hc97omv.js +0 -28
- package/dist/countries-DfLkrF0x.js +0 -616
- package/dist/dateInputComposed-C7PCzh-U.js +0 -173
- package/dist/documentCapture-C0mO-RGE.js +0 -692
- package/dist/dropdownComposed-BpinYlrx.js +0 -367
- package/dist/ekybModule-Dr6LJUg-.js +0 -357
- package/dist/ekycModule-C3mswduI.js +0 -291
- package/dist/errorContent-Cb8nmQAE.js +0 -44
- package/dist/errorIcon-DEARBrGx.js +0 -26
- package/dist/faceMatch-DbDp7D3d.js +0 -237
- package/dist/fileIcon-CCSvS10T.js +0 -52
- package/dist/flip-animation-COR596wy.js +0 -29
- package/dist/flipAnimation-BqV462TA.js +0 -2059
- package/dist/formField-CP6wDdfA.js +0 -106
- package/dist/front-horizontal-hint-lRLKd7vY.js +0 -7
- package/dist/front-vertical-hint-qQoJXRE3.js +0 -7
- package/dist/frontdevicelottie-KhKxT5n9.js +0 -29
- package/dist/glaredevicelottie-DLuIStvb.js +0 -29
- package/dist/id-laser-h-BBV3r3rz.js +0 -29
- package/dist/id-laser-v-BTHJaSfx.js +0 -29
- package/dist/id-tutorial-B-F5Q28m.js +0 -29
- package/dist/incodeModule-C4XIllao.js +0 -96
- package/dist/inputComposed-fUbAGrDy.js +0 -103
- package/dist/instance-BWYzq8dk.js +0 -2163
- package/dist/loadingIcon-DmuPXh70.js +0 -195
- package/dist/mandatoryConsent-5xPI0cor.js +0 -94
- package/dist/manualCaptureButton-BvFmTyJe.js +0 -372
- package/dist/numberedStep-DwUB__mh.js +0 -5
- package/dist/otpInput-BFXhqFRT.js +0 -156
- package/dist/page-SrUl0qtN.js +0 -69
- package/dist/passport-horizontal-hint-BCtpMp1Y.js +0 -5
- package/dist/passport-tutorial-CaYBFTqt.js +0 -29
- package/dist/passport-vertical-hint-GaLnzqHP.js +0 -5
- package/dist/permissions-DT4Fz9MR.js +0 -709
- package/dist/phoneInput-CGr8TxOO.js +0 -158
- package/dist/phoneInputComposed-Cm9O2Jba.js +0 -206
- package/dist/processing-szVOCQwZ.js +0 -19
- package/dist/richText-cspvNz2a.js +0 -1807
- package/dist/selfieTutorial-Dm_p0ke9.js +0 -29
- package/dist/spinner-DygONskw.js +0 -60
- package/dist/successIcon-Bjsdc4lF.js +0 -26
- package/dist/tutorial-Cdz1025D.js +0 -473
- package/dist/types/ekyb/styles.d.ts +0 -1
- package/dist/types/ekyc/styles.d.ts +0 -1
- package/dist/typography-BDACYR5i.js +0 -14
- package/dist/uiConfig-Dnt-2YWB.js +0 -23
- package/dist/useMediaQuery-lJdQBmC2.js +0 -18
- package/dist/vendor-preact-BoMmvSgn.js +0 -694
- package/dist/warningIcon-DQq_MrOB.js +0 -26
|
@@ -1,313 +1,271 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import "
|
|
5
|
-
import "../
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
13
|
-
import
|
|
14
|
-
import {
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
}
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
/* @__PURE__ */ e("h2", { class: "IncodeCurpSuccessTitle", children: a("curp.status.verified") ?? "Verified" })
|
|
273
|
-
] }) });
|
|
274
|
-
if (t.status === "failure" || t.status === "generateError") {
|
|
275
|
-
const r = t.retriesLeft > 0, m = t.status === "failure" ? a("curp.status.notVerified") ?? "Not verified" : a("curp.status.couldntGenerate") ?? "Couldn't generate CURP";
|
|
276
|
-
return /* @__PURE__ */ e(p, { className: "IncodeCurpValidationPage", children: /* @__PURE__ */ e("div", { class: "IncodeCurpValidation IncodeCurpFailure", children: [
|
|
277
|
-
/* @__PURE__ */ e(u, {}),
|
|
278
|
-
/* @__PURE__ */ e(U, { size: 32 }),
|
|
279
|
-
/* @__PURE__ */ e(u, { size: 16 }),
|
|
280
|
-
/* @__PURE__ */ e("h2", { class: "IncodeCurpFailureTitle", children: m }),
|
|
281
|
-
t.status === "generateError" && r && /* @__PURE__ */ e(y, { children: [
|
|
282
|
-
/* @__PURE__ */ e(u, { size: 12 }),
|
|
283
|
-
/* @__PURE__ */ e("p", { class: "IncodeCurpFailureHint", children: a("curp.status.checkInfo") ?? "Please check your information" })
|
|
284
|
-
] }),
|
|
285
|
-
/* @__PURE__ */ e(u, {}),
|
|
286
|
-
r && /* @__PURE__ */ e(y, { children: /* @__PURE__ */ e(
|
|
287
|
-
h,
|
|
288
|
-
{
|
|
289
|
-
type: "button",
|
|
290
|
-
onClick: () => s.retry(),
|
|
291
|
-
"data-testid": "curp-retry",
|
|
292
|
-
children: t.status === "failure" ? a("curp.status.tryAgain") ?? "Try again" : a("curp.status.edit") ?? "Edit information"
|
|
293
|
-
}
|
|
294
|
-
) })
|
|
295
|
-
] }) });
|
|
296
|
-
}
|
|
297
|
-
return t.status === "finished" ? (d?.(), null) : (t.status === "closed" && o?.(void 0), null);
|
|
298
|
-
}, z = ({
|
|
299
|
-
config: i,
|
|
300
|
-
onFinish: d,
|
|
301
|
-
onError: o
|
|
302
|
-
}) => /* @__PURE__ */ e(S, { children: i ? /* @__PURE__ */ e(
|
|
303
|
-
H,
|
|
304
|
-
{
|
|
305
|
-
config: i,
|
|
306
|
-
onFinish: d,
|
|
307
|
-
onError: o
|
|
308
|
-
}
|
|
309
|
-
) : null });
|
|
310
|
-
E(z, "incode-curp-validation");
|
|
311
|
-
export {
|
|
312
|
-
z as CurpValidation
|
|
313
|
-
};
|
|
1
|
+
import { n as e } from "../i18n-DZOHbK9q.js";
|
|
2
|
+
import { S as t, v as n } from "../vendor-preact-D6SntenC.js";
|
|
3
|
+
import { c as r, r as i } from "../loadingIcon-CeQt7Zgb.js";
|
|
4
|
+
import { t as a } from "../spacer-DCljE53A.js";
|
|
5
|
+
import { t as o } from "../button-DhL5eRT3.js";
|
|
6
|
+
import { t as s } from "../page-SvlJWUfz.js";
|
|
7
|
+
import { t as c } from "../spinner-snIGzmm8.js";
|
|
8
|
+
import "../spinner-Bk0YuoLu.js";
|
|
9
|
+
import { p as l } from "../icons-BHbofCgJ.js";
|
|
10
|
+
import { t as u } from "../successIcon-AHrfmJvv.js";
|
|
11
|
+
import { t as d } from "../inputComposed-BhbfD8Ru.js";
|
|
12
|
+
import { t as f } from "../dropdownComposed-_Ey7wJNG.js";
|
|
13
|
+
import "../dateInputComposed-B9WqdYx9.js";
|
|
14
|
+
import { t as p } from "../dateInputComposed-ndsGHX1M.js";
|
|
15
|
+
import { t as m } from "../incodeModule-Bf6yJ8RB.js";
|
|
16
|
+
import { createCurpValidationManager as h, mexicanStates as g } from "@incodetech/core/curp-validation";
|
|
17
|
+
//#region src/modules/curp-validation/curpInput.tsx
|
|
18
|
+
var _ = ({ curp: t, isValid: r, onCurpChange: i, onVerify: s, onSwitchToGenerate: c, disabled: l = !1, placeholder: u, continueLabel: f, dontHaveLabel: p }) => {
|
|
19
|
+
let { t: m } = e(), h = u ?? m("curp.placeholder.curp") ?? "CURP", g = f ?? m("curp.continue") ?? "Continue", _ = p ?? m("curp.dontHave") ?? "I don't have my CURP", v = m("curp.placeholder.curp") ?? "CURP";
|
|
20
|
+
return /* @__PURE__ */ n("div", {
|
|
21
|
+
class: "IncodeCurpValidation IncodeCurpInput",
|
|
22
|
+
children: [
|
|
23
|
+
/* @__PURE__ */ n(d, {
|
|
24
|
+
id: "curp-input",
|
|
25
|
+
label: "",
|
|
26
|
+
value: t,
|
|
27
|
+
onInput: (e) => {
|
|
28
|
+
let t = e.target;
|
|
29
|
+
i(t.value.toUpperCase());
|
|
30
|
+
},
|
|
31
|
+
placeholder: h,
|
|
32
|
+
disabled: l,
|
|
33
|
+
maxLength: 18,
|
|
34
|
+
"aria-label": v
|
|
35
|
+
}),
|
|
36
|
+
/* @__PURE__ */ n(a, {}),
|
|
37
|
+
/* @__PURE__ */ n(o, {
|
|
38
|
+
type: "button",
|
|
39
|
+
onClick: s,
|
|
40
|
+
disabled: !r || l,
|
|
41
|
+
"data-testid": "curp-verify",
|
|
42
|
+
children: g
|
|
43
|
+
}),
|
|
44
|
+
/* @__PURE__ */ n(o, {
|
|
45
|
+
type: "button",
|
|
46
|
+
onClick: c,
|
|
47
|
+
disabled: l,
|
|
48
|
+
"data-testid": "curp-switch-to-generate",
|
|
49
|
+
class: "IncodeCurpInputDontHaveButton",
|
|
50
|
+
children: _
|
|
51
|
+
})
|
|
52
|
+
]
|
|
53
|
+
});
|
|
54
|
+
}, v = ({ form: t, isValid: r, onFormChange: i, onGenerate: s, disabled: c = !1, labels: l }) => {
|
|
55
|
+
let { t: u } = e(), m = {
|
|
56
|
+
firstName: u("curp.labels.firstName") ?? "Your First name",
|
|
57
|
+
firstLast: u("curp.labels.firstLast") ?? "Your First last name",
|
|
58
|
+
secondLast: u("curp.labels.secondLast") ?? "Your Second last name",
|
|
59
|
+
gender: u("curp.labels.genderV2") ?? "Gender",
|
|
60
|
+
genderPlaceholder: u("curp.placeholder.gender") ?? "Choose gender",
|
|
61
|
+
male: u("curp.labels.maleV2") ?? "Male",
|
|
62
|
+
female: u("curp.labels.femaleV2") ?? "Female",
|
|
63
|
+
other: u("curp.labels.other") ?? "Other",
|
|
64
|
+
dob: u("curp.labels.dob") ?? "Date of birth",
|
|
65
|
+
birthState: u("curp.labels.birthState") ?? "State of birth",
|
|
66
|
+
statePlaceholder: u("curp.placeholder.state") ?? "Select state",
|
|
67
|
+
generate: u("curp.generateCta") ?? "Generate CURP",
|
|
68
|
+
...l
|
|
69
|
+
}, h = (e) => (t) => {
|
|
70
|
+
let n = t.target;
|
|
71
|
+
i({ [e]: n.value });
|
|
72
|
+
}, _ = [
|
|
73
|
+
{
|
|
74
|
+
value: "H",
|
|
75
|
+
label: m.male
|
|
76
|
+
},
|
|
77
|
+
{
|
|
78
|
+
value: "M",
|
|
79
|
+
label: m.female
|
|
80
|
+
},
|
|
81
|
+
{
|
|
82
|
+
value: "X",
|
|
83
|
+
label: m.other
|
|
84
|
+
}
|
|
85
|
+
], v = g.map((e) => ({
|
|
86
|
+
value: e.value,
|
|
87
|
+
label: e.label
|
|
88
|
+
}));
|
|
89
|
+
return /* @__PURE__ */ n("div", {
|
|
90
|
+
class: "IncodeCurpValidation IncodeGenerateCurpForm",
|
|
91
|
+
children: [
|
|
92
|
+
/* @__PURE__ */ n(d, {
|
|
93
|
+
id: "curp-first-name",
|
|
94
|
+
label: m.firstName,
|
|
95
|
+
value: t.name,
|
|
96
|
+
onInput: h("name"),
|
|
97
|
+
placeholder: m.firstName,
|
|
98
|
+
disabled: c,
|
|
99
|
+
autoComplete: "given-name"
|
|
100
|
+
}),
|
|
101
|
+
/* @__PURE__ */ n(d, {
|
|
102
|
+
id: "curp-first-last",
|
|
103
|
+
label: m.firstLast,
|
|
104
|
+
value: t.firstLastName,
|
|
105
|
+
onInput: h("firstLastName"),
|
|
106
|
+
placeholder: m.firstLast,
|
|
107
|
+
disabled: c
|
|
108
|
+
}),
|
|
109
|
+
/* @__PURE__ */ n(d, {
|
|
110
|
+
id: "curp-second-last",
|
|
111
|
+
label: m.secondLast,
|
|
112
|
+
value: t.secondLastName,
|
|
113
|
+
onInput: h("secondLastName"),
|
|
114
|
+
placeholder: m.secondLast,
|
|
115
|
+
disabled: c
|
|
116
|
+
}),
|
|
117
|
+
/* @__PURE__ */ n(f, {
|
|
118
|
+
id: "curp-gender",
|
|
119
|
+
label: m.gender,
|
|
120
|
+
placeholder: m.genderPlaceholder,
|
|
121
|
+
value: t.gender,
|
|
122
|
+
options: _,
|
|
123
|
+
disabled: c,
|
|
124
|
+
onChange: (e) => i({ gender: e }),
|
|
125
|
+
"data-testid": "curp-gender"
|
|
126
|
+
}),
|
|
127
|
+
/* @__PURE__ */ n(p, {
|
|
128
|
+
id: "curp-birth-date",
|
|
129
|
+
label: m.dob,
|
|
130
|
+
value: t.birthDate,
|
|
131
|
+
onInput: h("birthDate"),
|
|
132
|
+
max: (/* @__PURE__ */ new Date()).toISOString().split("T")[0],
|
|
133
|
+
placeholder: u("curp.placeholder.dob") ?? "mm/dd/yyyy",
|
|
134
|
+
disabled: c,
|
|
135
|
+
"data-testid": "curp-birth-date"
|
|
136
|
+
}),
|
|
137
|
+
/* @__PURE__ */ n(f, {
|
|
138
|
+
id: "curp-birth-state",
|
|
139
|
+
label: m.birthState,
|
|
140
|
+
placeholder: m.statePlaceholder,
|
|
141
|
+
value: t.birthState,
|
|
142
|
+
options: v,
|
|
143
|
+
disabled: c,
|
|
144
|
+
onChange: (e) => i({ birthState: e }),
|
|
145
|
+
"data-testid": "curp-birth-state",
|
|
146
|
+
searchable: !0
|
|
147
|
+
}),
|
|
148
|
+
/* @__PURE__ */ n(a, { size: 16 }),
|
|
149
|
+
/* @__PURE__ */ n(o, {
|
|
150
|
+
type: "button",
|
|
151
|
+
onClick: s,
|
|
152
|
+
disabled: !r || c,
|
|
153
|
+
"data-testid": "curp-generate",
|
|
154
|
+
children: m.generate
|
|
155
|
+
})
|
|
156
|
+
]
|
|
157
|
+
});
|
|
158
|
+
}, y = ({ config: i, onFinish: d, onError: f }) => {
|
|
159
|
+
let { t: p } = e(), [m, g] = r(() => {
|
|
160
|
+
if (!i) throw Error("CURP validation config is required");
|
|
161
|
+
return h({ config: i });
|
|
162
|
+
});
|
|
163
|
+
if (m.status === "idle" || m.status === "loading" || m.status === "verifying" || m.status === "generating") return /* @__PURE__ */ n(s, {
|
|
164
|
+
className: "IncodeCurpValidationPage",
|
|
165
|
+
children: /* @__PURE__ */ n("div", {
|
|
166
|
+
class: "IncodeCurpValidation IncodeCurpLoading",
|
|
167
|
+
children: /* @__PURE__ */ n(c, {
|
|
168
|
+
title: m.status === "generating" ? p("curp.status.generating") ?? "Generating..." : p("curp.status.verifying") ?? "Verifying...",
|
|
169
|
+
fullScreen: !1
|
|
170
|
+
})
|
|
171
|
+
})
|
|
172
|
+
});
|
|
173
|
+
if (m.status === "enterCurp") return /* @__PURE__ */ n(s, {
|
|
174
|
+
className: "IncodeCurpValidationPage",
|
|
175
|
+
title: p("curp.enterCurp") ?? "Enter your CURP",
|
|
176
|
+
children: /* @__PURE__ */ n(_, {
|
|
177
|
+
curp: m.curp,
|
|
178
|
+
isValid: m.isValid,
|
|
179
|
+
onCurpChange: (e) => g.setCurp(e),
|
|
180
|
+
onVerify: () => g.verify(),
|
|
181
|
+
onSwitchToGenerate: () => g.switchToGenerate(),
|
|
182
|
+
placeholder: p("curp.placeholder.curp") ?? "CURP",
|
|
183
|
+
continueLabel: p("curp.continue") ?? "Continue",
|
|
184
|
+
dontHaveLabel: p("curp.dontHave") ?? "I don't have my CURP"
|
|
185
|
+
})
|
|
186
|
+
});
|
|
187
|
+
if (m.status === "generateCurp") return /* @__PURE__ */ n(s, {
|
|
188
|
+
className: "IncodeCurpValidationPage",
|
|
189
|
+
title: p("curp.generate") ?? "Generate your CURP",
|
|
190
|
+
children: /* @__PURE__ */ n(v, {
|
|
191
|
+
form: m.form,
|
|
192
|
+
isValid: m.isValid,
|
|
193
|
+
onFormChange: (e) => g.setGenerateForm(e),
|
|
194
|
+
onGenerate: () => g.generate()
|
|
195
|
+
})
|
|
196
|
+
});
|
|
197
|
+
if (m.status === "confirmCurp") return /* @__PURE__ */ n(s, {
|
|
198
|
+
className: "IncodeCurpValidationPage",
|
|
199
|
+
title: p("curp.status.confirm") ?? "Confirm your CURP",
|
|
200
|
+
children: /* @__PURE__ */ n("div", {
|
|
201
|
+
class: "IncodeCurpValidation IncodeCurpConfirm",
|
|
202
|
+
children: [
|
|
203
|
+
/* @__PURE__ */ n("input", {
|
|
204
|
+
type: "text",
|
|
205
|
+
class: "IncodeCurpConfirmInput",
|
|
206
|
+
value: m.curp,
|
|
207
|
+
readOnly: !0,
|
|
208
|
+
"aria-label": p("curp.status.generatedCurp") ?? "Generated CURP"
|
|
209
|
+
}),
|
|
210
|
+
/* @__PURE__ */ n(a, {}),
|
|
211
|
+
/* @__PURE__ */ n(o, {
|
|
212
|
+
type: "button",
|
|
213
|
+
onClick: () => g.confirmGenerated(),
|
|
214
|
+
"data-testid": "curp-confirm",
|
|
215
|
+
children: p("curp.continue") ?? "Continue"
|
|
216
|
+
})
|
|
217
|
+
]
|
|
218
|
+
})
|
|
219
|
+
});
|
|
220
|
+
if (m.status === "success") return /* @__PURE__ */ n(s, {
|
|
221
|
+
className: "IncodeCurpValidationPage",
|
|
222
|
+
children: /* @__PURE__ */ n("div", {
|
|
223
|
+
class: "IncodeCurpValidation IncodeCurpSuccess",
|
|
224
|
+
children: [
|
|
225
|
+
/* @__PURE__ */ n(u, { size: 32 }),
|
|
226
|
+
/* @__PURE__ */ n(a, { size: 16 }),
|
|
227
|
+
/* @__PURE__ */ n("h2", {
|
|
228
|
+
class: "IncodeCurpSuccessTitle",
|
|
229
|
+
children: p("curp.status.verified") ?? "Verified"
|
|
230
|
+
})
|
|
231
|
+
]
|
|
232
|
+
})
|
|
233
|
+
});
|
|
234
|
+
if (m.status === "failure" || m.status === "generateError") {
|
|
235
|
+
let e = m.retriesLeft > 0, r = m.status === "failure" ? p("curp.status.notVerified") ?? "Not verified" : p("curp.status.couldntGenerate") ?? "Couldn't generate CURP";
|
|
236
|
+
return /* @__PURE__ */ n(s, {
|
|
237
|
+
className: "IncodeCurpValidationPage",
|
|
238
|
+
children: /* @__PURE__ */ n("div", {
|
|
239
|
+
class: "IncodeCurpValidation IncodeCurpFailure",
|
|
240
|
+
children: [
|
|
241
|
+
/* @__PURE__ */ n(a, {}),
|
|
242
|
+
/* @__PURE__ */ n(l, { size: 32 }),
|
|
243
|
+
/* @__PURE__ */ n(a, { size: 16 }),
|
|
244
|
+
/* @__PURE__ */ n("h2", {
|
|
245
|
+
class: "IncodeCurpFailureTitle",
|
|
246
|
+
children: r
|
|
247
|
+
}),
|
|
248
|
+
m.status === "generateError" && e && /* @__PURE__ */ n(t, { children: [/* @__PURE__ */ n(a, { size: 12 }), /* @__PURE__ */ n("p", {
|
|
249
|
+
class: "IncodeCurpFailureHint",
|
|
250
|
+
children: p("curp.status.checkInfo") ?? "Please check your information"
|
|
251
|
+
})] }),
|
|
252
|
+
/* @__PURE__ */ n(a, {}),
|
|
253
|
+
e && /* @__PURE__ */ n(t, { children: /* @__PURE__ */ n(o, {
|
|
254
|
+
type: "button",
|
|
255
|
+
onClick: () => g.retry(),
|
|
256
|
+
"data-testid": "curp-retry",
|
|
257
|
+
children: m.status === "failure" ? p("curp.status.tryAgain") ?? "Try again" : p("curp.status.edit") ?? "Edit information"
|
|
258
|
+
}) })
|
|
259
|
+
]
|
|
260
|
+
})
|
|
261
|
+
});
|
|
262
|
+
}
|
|
263
|
+
return m.status === "finished" ? (d?.(), null) : (m.status === "closed" && f?.(void 0), null);
|
|
264
|
+
}, b = ({ config: e, onFinish: t, onError: r }) => /* @__PURE__ */ n(i, { children: e ? /* @__PURE__ */ n(y, {
|
|
265
|
+
config: e,
|
|
266
|
+
onFinish: t,
|
|
267
|
+
onError: r
|
|
268
|
+
}) : null });
|
|
269
|
+
m(b, "incode-curp-validation");
|
|
270
|
+
//#endregion
|
|
271
|
+
export { b as CurpValidation };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! tailwindcss v4.
|
|
1
|
+
/*! tailwindcss v4.2.2 | MIT License | https://tailwindcss.com */
|
|
2
2
|
@layer properties {
|
|
3
3
|
@supports (((-webkit-hyphens: none)) and (not (margin-trim: inline))) or ((-moz-orient: inline) and (not (color: rgb(from red r g b)))) {
|
|
4
4
|
*, :before, :after, ::backdrop {
|