bry-biometric-collector 2.0.4 → 2.0.6
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/README.md +39 -8
- package/dist/CameraStatus_449f511b_2.0.6.js +319 -0
- package/dist/DocumentCollector_0fd5f391_2.0.6.js +1027 -0
- package/dist/FaceCollector_ac361443_2.0.6.js +1659 -0
- package/dist/bry-biometric-collector-main.js +1 -1
- package/dist/{en-us_5ebe727c_2.0.4.js → en-us_9e0134e1_2.0.6.js} +12 -8
- package/dist/{face_api_ebd7fa48_2.0.4.js → face_api_0e3ce8c8_2.0.6.js} +12823 -12646
- package/dist/{fingersApi_ae9e2572_2.0.4.js → fingersApi_e6d434bf_2.0.6.js} +12 -12
- package/dist/index.d.ts +20 -3
- package/dist/index.js +1 -1
- package/dist/{main_14ce11df_2.0.4.js → main_baf553c3_2.0.6.js} +7427 -6884
- package/dist/{pt-br_cb19a314_2.0.4.js → pt-br_64defcaa_2.0.6.js} +12 -8
- package/dist/style.css +1 -1
- package/package.json +4 -4
- package/dist/FaceCollector_2518984f_2.0.4.js +0 -1879
- /package/dist/{index-no-detector_c7c1d3a2_2.0.4.js → index-no-detector_c7c1d3a2_2.0.6.js} +0 -0
@@ -1,1879 +0,0 @@
|
|
1
|
-
import { w as yt, S as tl, r as ll, t as Ot, x as il, y as p, z as Me, B as h, C as G, D as o, E as w, G as S, H as $e, I as Nt, J as Z, K as L, L as We, M as u, N as se, O as _t, P as q, Q as Bl, R as It, T, U as At, V as W, W as sl, Y as Ne, Z as al, _ as Fe, $ as St, a0 as gt, a1 as lt, a2 as vt, a3 as Ft, a4 as Je, a5 as Hl, X as Ul, a6 as Vl, a7 as Re, a8 as Kl, a9 as Ge, aa as it, ab as wt, ac as kt, ad as xe, ae as jl, af as ql, ag as ot, ah as Ct, ai as zl, aj as nt, ak as Wt, al as Bt, am as Ht, an as Zl, ao as Et, ap as Ut, aq as Vt, ar as Ql, as as Xl, at as Jl, au as Gl, av as Yl, aw as k, ax as Kt, ay as jt, f as $l, az as ei, aA as rt, aB as J, aC as ct, aD as ut, A as qt, aE as Rt, aF as ft, aG as ti, aH as li, aI as ii, aJ as si, aK as Ye, aL as ai, aM as oi, aN as bt, aO as dt, aP as ol, l as Pt, aQ as ye, aR as Lt, aS as ni, aT as ri, aU as zt, aV as mt, aW as ci, aX as ui } from "./main_14ce11df_2.0.4.js";
|
2
|
-
var re = /* @__PURE__ */ ((l) => (l.OK = "OK", l.DEVICE_NOT_FOUND_ERROR = "DEVICE_NOT_FOUND_ERROR", l.CAMERA_DENIED_ERROR = "CAMERA_DENIED_ERROR", l.CAMERA_IN_USE_ERROR = "CAMERA_IN_USE_ERROR", l.CAMERA_CLOSED_ERROR = "CAMERA_CLOSED_ERROR", l))(re || {});
|
3
|
-
const Ke = yt(
|
4
|
-
"OK"
|
5
|
-
/* OK */
|
6
|
-
);
|
7
|
-
function fi(l) {
|
8
|
-
let e, t, s, a, c, d, m, n, f, g, E = [
|
9
|
-
{ class: "text-[8em] mx-auto" },
|
10
|
-
{ xmlns: "http://www.w3.org/2000/svg" },
|
11
|
-
{ width: "1em" },
|
12
|
-
{ height: "1em" },
|
13
|
-
{ viewBox: "0 0 256 256" },
|
14
|
-
/*$$props*/
|
15
|
-
l[2]
|
16
|
-
], b = {};
|
17
|
-
for (let r = 0; r < E.length; r += 1)
|
18
|
-
b = $e(b, E[r]);
|
19
|
-
return {
|
20
|
-
c() {
|
21
|
-
e = Z("svg"), t = Z("path"), s = L(), a = h("span"), a.textContent = "Por favor, permaneça na mesma aba durante a coleta biométrica.", c = L(), d = h("span"), d.textContent = "Clique no botão Reiniciar para capturar novamente.", m = L(), n = h("button"), n.textContent = "Reiniciar", o(t, "fill", "currentColor"), o(t, "d", "M236.8 188.09L149.35 36.22a24.76 24.76 0 0 0-42.7 0L19.2 188.09a23.51 23.51 0 0 0 0 23.72A24.35 24.35 0 0 0 40.55 224h174.9a24.35 24.35 0 0 0 21.33-12.19a23.51 23.51 0 0 0 .02-23.72m-13.87 15.71a8.5 8.5 0 0 1-7.48 4.2H40.55a8.5 8.5 0 0 1-7.48-4.2a7.59 7.59 0 0 1 0-7.72l87.45-151.87a8.75 8.75 0 0 1 15 0l87.45 151.87a7.59 7.59 0 0 1-.04 7.72M120 144v-40a8 8 0 0 1 16 0v40a8 8 0 0 1-16 0m20 36a12 12 0 1 1-12-12a12 12 0 0 1 12 12"), We(e, b), o(a, "class", "text-xl font-bold text-center"), o(d, "class", "m-auto text-base block text-center"), o(n, "class", "z-20 ce-dui-btn ce-dui-btn-outline ce-dui-btn-primary m-auto");
|
22
|
-
},
|
23
|
-
m(r, _) {
|
24
|
-
p(r, e, _), u(e, t), p(r, s, _), p(r, a, _), p(r, c, _), p(r, d, _), p(r, m, _), p(r, n, _), f || (g = se(
|
25
|
-
n,
|
26
|
-
"click",
|
27
|
-
/*click_handler_3*/
|
28
|
-
l[6]
|
29
|
-
), f = !0);
|
30
|
-
},
|
31
|
-
p(r, _) {
|
32
|
-
We(e, b = _t(E, [
|
33
|
-
{ class: "text-[8em] mx-auto" },
|
34
|
-
{ xmlns: "http://www.w3.org/2000/svg" },
|
35
|
-
{ width: "1em" },
|
36
|
-
{ height: "1em" },
|
37
|
-
{ viewBox: "0 0 256 256" },
|
38
|
-
_ & /*$$props*/
|
39
|
-
4 && /*$$props*/
|
40
|
-
r[2]
|
41
|
-
]));
|
42
|
-
},
|
43
|
-
d(r) {
|
44
|
-
r && w(e), r && w(s), r && w(a), r && w(c), r && w(d), r && w(m), r && w(n), f = !1, g();
|
45
|
-
}
|
46
|
-
};
|
47
|
-
}
|
48
|
-
function di(l) {
|
49
|
-
let e, t, s, a, c, d, m, n, f, g, E = [
|
50
|
-
{ class: "text-[8em] mx-auto" },
|
51
|
-
{ xmlns: "http://www.w3.org/2000/svg" },
|
52
|
-
{ width: "1em" },
|
53
|
-
{ height: "1em" },
|
54
|
-
{ viewBox: "0 0 256 256" },
|
55
|
-
/*$$props*/
|
56
|
-
l[2]
|
57
|
-
], b = {};
|
58
|
-
for (let r = 0; r < E.length; r += 1)
|
59
|
-
b = $e(b, E[r]);
|
60
|
-
return {
|
61
|
-
c() {
|
62
|
-
e = Z("svg"), t = Z("path"), s = L(), a = h("span"), a.textContent = "A câmera está em uso.", c = L(), d = h("span"), d.textContent = "Certifique-se de que a câmera não está sendo utilizada por nenhuma outra aplicação e clique no botão abaixo.", m = L(), n = h("button"), n.textContent = "Reiniciar", o(t, "fill", "currentColor"), o(t, "d", "M56.88 31.93a12 12 0 1 0-17.76 16.14l4 4.37A28 28 0 0 0 20 80v112a28 28 0 0 0 28 28h147.42l3.7 4.07a12 12 0 0 0 17.76-16.14Zm49.35 90L136 154.64a24 24 0 0 1-29.77-32.75ZM48 196a4 4 0 0 1-4-4V80a4 4 0 0 1 4-4h16.51l24.92 27.41a48 48 0 0 0 63.34 69.67L173.6 196ZM236 80v94.14a12 12 0 0 1-24 0V80a4 4 0 0 0-4-4h-32a12 12 0 0 1-10-5.34L153.57 52h-51.51a12 12 0 0 1 0-24H160a12 12 0 0 1 10 5.34L182.42 52H208a28 28 0 0 1 28 28"), We(e, b), o(a, "class", "text-xl font-bold text-center"), o(d, "class", "m-auto text-base block text-center"), o(n, "class", "z-20 ce-dui-btn ce-dui-btn-outline ce-dui-btn-primary m-auto");
|
63
|
-
},
|
64
|
-
m(r, _) {
|
65
|
-
p(r, e, _), u(e, t), p(r, s, _), p(r, a, _), p(r, c, _), p(r, d, _), p(r, m, _), p(r, n, _), f || (g = se(
|
66
|
-
n,
|
67
|
-
"click",
|
68
|
-
/*click_handler_2*/
|
69
|
-
l[5]
|
70
|
-
), f = !0);
|
71
|
-
},
|
72
|
-
p(r, _) {
|
73
|
-
We(e, b = _t(E, [
|
74
|
-
{ class: "text-[8em] mx-auto" },
|
75
|
-
{ xmlns: "http://www.w3.org/2000/svg" },
|
76
|
-
{ width: "1em" },
|
77
|
-
{ height: "1em" },
|
78
|
-
{ viewBox: "0 0 256 256" },
|
79
|
-
_ & /*$$props*/
|
80
|
-
4 && /*$$props*/
|
81
|
-
r[2]
|
82
|
-
]));
|
83
|
-
},
|
84
|
-
d(r) {
|
85
|
-
r && w(e), r && w(s), r && w(a), r && w(c), r && w(d), r && w(m), r && w(n), f = !1, g();
|
86
|
-
}
|
87
|
-
};
|
88
|
-
}
|
89
|
-
function mi(l) {
|
90
|
-
let e, t, s, a, c, d, m, n, f, g, E = [
|
91
|
-
{ class: "text-[8em] mx-auto" },
|
92
|
-
{ xmlns: "http://www.w3.org/2000/svg" },
|
93
|
-
{ width: "1em" },
|
94
|
-
{ height: "1em" },
|
95
|
-
{ viewBox: "0 0 256 256" },
|
96
|
-
/*$$props*/
|
97
|
-
l[2]
|
98
|
-
], b = {};
|
99
|
-
for (let r = 0; r < E.length; r += 1)
|
100
|
-
b = $e(b, E[r]);
|
101
|
-
return {
|
102
|
-
c() {
|
103
|
-
e = Z("svg"), t = Z("path"), s = L(), a = h("span"), a.textContent = "A câmera não foi detectada.", c = L(), d = h("span"), d.textContent = "Por favor, conecte a sua câmera, espere alguns instantes e clique no botão Reiniciar.", m = L(), n = h("button"), n.textContent = "Reiniciar", o(t, "fill", "currentColor"), o(t, "d", "m137 168l11.52-11.51a12 12 0 0 0-17-17L120 151l-15-15l11.52-11.51a12 12 0 0 0-17-17L88 119l-15.51-15.49a12 12 0 0 0-17 17L59 124l-20.46 20.49a36 36 0 0 0 0 50.91l2.55 2.54l-25.58 25.57a12 12 0 0 0 17 17l25.57-25.58l2.54 2.55a36.06 36.06 0 0 0 50.91 0L132 197l3.51 3.52a12 12 0 0 0 17-17Zm-42.46 32.49a12 12 0 0 1-17 0l-22.03-22.06a12 12 0 0 1 0-17L76 141l39 39Zm146-185a12 12 0 0 0-17 0l-25.6 25.6l-2.54-2.55a36.05 36.05 0 0 0-50.91 0L124 59l-3.51-3.52a12 12 0 0 0-17 17l80 80a12 12 0 0 0 17-17L197 132l20.49-20.49a36 36 0 0 0 0-50.91l-2.55-2.54l25.58-25.57a12 12 0 0 0-.03-16.98Zm-40 79L180 115l-39-39l20.49-20.49a12 12 0 0 1 17 0l22.06 22.06a12 12 0 0 1 0 17Z"), We(e, b), o(a, "class", "text-xl font-bold text-center"), o(d, "class", "m-auto text-base block text-center"), o(n, "class", "z-20 ce-dui-btn ce-dui-btn-outline ce-dui-btn-primary m-auto");
|
104
|
-
},
|
105
|
-
m(r, _) {
|
106
|
-
p(r, e, _), u(e, t), p(r, s, _), p(r, a, _), p(r, c, _), p(r, d, _), p(r, m, _), p(r, n, _), f || (g = se(
|
107
|
-
n,
|
108
|
-
"click",
|
109
|
-
/*click_handler_1*/
|
110
|
-
l[4]
|
111
|
-
), f = !0);
|
112
|
-
},
|
113
|
-
p(r, _) {
|
114
|
-
We(e, b = _t(E, [
|
115
|
-
{ class: "text-[8em] mx-auto" },
|
116
|
-
{ xmlns: "http://www.w3.org/2000/svg" },
|
117
|
-
{ width: "1em" },
|
118
|
-
{ height: "1em" },
|
119
|
-
{ viewBox: "0 0 256 256" },
|
120
|
-
_ & /*$$props*/
|
121
|
-
4 && /*$$props*/
|
122
|
-
r[2]
|
123
|
-
]));
|
124
|
-
},
|
125
|
-
d(r) {
|
126
|
-
r && w(e), r && w(s), r && w(a), r && w(c), r && w(d), r && w(m), r && w(n), f = !1, g();
|
127
|
-
}
|
128
|
-
};
|
129
|
-
}
|
130
|
-
function _i(l) {
|
131
|
-
let e, t, s, a, c, d, m, n, f, g, E = [
|
132
|
-
{ class: "text-[8em] mx-auto" },
|
133
|
-
{ xmlns: "http://www.w3.org/2000/svg" },
|
134
|
-
{ width: "1em" },
|
135
|
-
{ height: "1em" },
|
136
|
-
{ viewBox: "0 0 256 256" },
|
137
|
-
/*$$props*/
|
138
|
-
l[2]
|
139
|
-
], b = {};
|
140
|
-
for (let r = 0; r < E.length; r += 1)
|
141
|
-
b = $e(b, E[r]);
|
142
|
-
return {
|
143
|
-
c() {
|
144
|
-
e = Z("svg"), t = Z("path"), s = L(), a = h("span"), a.textContent = "Por favor, conceda permissão de acesso à câmera.", c = L(), d = h("span"), d.textContent = "Após conceder a permissão, clique no botão Reiniciar.", m = L(), n = h("button"), n.textContent = "Reiniciar", o(t, "fill", "currentColor"), o(t, "d", "M249.45 69.31a12 12 0 0 0-12.51 1L212 88.43V72a20 20 0 0 0-20-20h-68.12a12 12 0 0 0 0 24H188v68a12 12 0 0 0 4.46 9.33c.15.13.31.25.48.38l44 32A12 12 0 0 0 256 176V80a12 12 0 0 0-6.55-10.69M232 152.43l-20-14.54v-19.78l20-14.54ZM56.88 31.93a12 12 0 1 0-17.76 16.14L42.69 52H32a20 20 0 0 0-20 20v112a20 20 0 0 0 20 20h148.87l18.25 20.07a12 12 0 0 0 17.76-16.14ZM36 180V76h28.51l94.55 104Z"), We(e, b), o(a, "class", "text-xl font-bold text-center"), o(d, "class", "m-auto text-base block text-center"), o(n, "class", "z-20 ce-dui-btn ce-dui-btn-outline ce-dui-btn-primary m-auto");
|
145
|
-
},
|
146
|
-
m(r, _) {
|
147
|
-
p(r, e, _), u(e, t), p(r, s, _), p(r, a, _), p(r, c, _), p(r, d, _), p(r, m, _), p(r, n, _), f || (g = se(
|
148
|
-
n,
|
149
|
-
"click",
|
150
|
-
/*click_handler*/
|
151
|
-
l[3]
|
152
|
-
), f = !0);
|
153
|
-
},
|
154
|
-
p(r, _) {
|
155
|
-
We(e, b = _t(E, [
|
156
|
-
{ class: "text-[8em] mx-auto" },
|
157
|
-
{ xmlns: "http://www.w3.org/2000/svg" },
|
158
|
-
{ width: "1em" },
|
159
|
-
{ height: "1em" },
|
160
|
-
{ viewBox: "0 0 256 256" },
|
161
|
-
_ & /*$$props*/
|
162
|
-
4 && /*$$props*/
|
163
|
-
r[2]
|
164
|
-
]));
|
165
|
-
},
|
166
|
-
d(r) {
|
167
|
-
r && w(e), r && w(s), r && w(a), r && w(c), r && w(d), r && w(m), r && w(n), f = !1, g();
|
168
|
-
}
|
169
|
-
};
|
170
|
-
}
|
171
|
-
function bi(l) {
|
172
|
-
let e;
|
173
|
-
function t(c, d) {
|
174
|
-
if (
|
175
|
-
/*$cameraStatusStore*/
|
176
|
-
c[1] === re.CAMERA_DENIED_ERROR
|
177
|
-
)
|
178
|
-
return _i;
|
179
|
-
if (
|
180
|
-
/*$cameraStatusStore*/
|
181
|
-
c[1] === re.DEVICE_NOT_FOUND_ERROR
|
182
|
-
)
|
183
|
-
return mi;
|
184
|
-
if (
|
185
|
-
/*$cameraStatusStore*/
|
186
|
-
c[1] === re.CAMERA_IN_USE_ERROR
|
187
|
-
)
|
188
|
-
return di;
|
189
|
-
if (
|
190
|
-
/*$cameraStatusStore*/
|
191
|
-
c[1] === re.CAMERA_CLOSED_ERROR
|
192
|
-
)
|
193
|
-
return fi;
|
194
|
-
}
|
195
|
-
let s = t(l), a = s && s(l);
|
196
|
-
return {
|
197
|
-
c() {
|
198
|
-
e = h("div"), a && a.c(), this.c = G, o(e, "class", "flex flex-col gap-4 justify-center absolute -translate-y-1/2 -translate-x-1/2 top-1/2 left-1/2 overflow-visible text-nowrap");
|
199
|
-
},
|
200
|
-
m(c, d) {
|
201
|
-
p(c, e, d), a && a.m(e, null);
|
202
|
-
},
|
203
|
-
p(c, [d]) {
|
204
|
-
s === (s = t(c)) && a ? a.p(c, d) : (a && a.d(1), a = s && s(c), a && (a.c(), a.m(e, null)));
|
205
|
-
},
|
206
|
-
i: G,
|
207
|
-
o: G,
|
208
|
-
d(c) {
|
209
|
-
c && w(e), a && a.d();
|
210
|
-
}
|
211
|
-
};
|
212
|
-
}
|
213
|
-
function hi(l, e, t) {
|
214
|
-
let s;
|
215
|
-
S(l, Ke, (f) => t(1, s = f));
|
216
|
-
let { handler: a = () => {
|
217
|
-
} } = e;
|
218
|
-
const c = () => {
|
219
|
-
a(), console.log("canicna", a);
|
220
|
-
}, d = () => {
|
221
|
-
a(), console.log("canicna", a);
|
222
|
-
}, m = () => {
|
223
|
-
a(), console.log("canicna", a);
|
224
|
-
}, n = () => {
|
225
|
-
a();
|
226
|
-
};
|
227
|
-
return l.$$set = (f) => {
|
228
|
-
t(2, e = $e($e({}, e), Nt(f))), "handler" in f && t(0, a = f.handler);
|
229
|
-
}, e = Nt(e), [
|
230
|
-
a,
|
231
|
-
s,
|
232
|
-
e,
|
233
|
-
c,
|
234
|
-
d,
|
235
|
-
m,
|
236
|
-
n
|
237
|
-
];
|
238
|
-
}
|
239
|
-
class nl extends tl {
|
240
|
-
constructor(e) {
|
241
|
-
super(), ll(
|
242
|
-
this,
|
243
|
-
{
|
244
|
-
target: this.shadowRoot,
|
245
|
-
props: il(this.attributes),
|
246
|
-
customElement: !0
|
247
|
-
},
|
248
|
-
hi,
|
249
|
-
bi,
|
250
|
-
Ot,
|
251
|
-
{ handler: 0 },
|
252
|
-
null
|
253
|
-
), e && (e.target && p(e.target, this, e.anchor), e.props && (this.$set(e.props), Me()));
|
254
|
-
}
|
255
|
-
static get observedAttributes() {
|
256
|
-
return ["handler"];
|
257
|
-
}
|
258
|
-
get handler() {
|
259
|
-
return this.$$.ctx[0];
|
260
|
-
}
|
261
|
-
set handler(e) {
|
262
|
-
this.$$set({ handler: e }), Me();
|
263
|
-
}
|
264
|
-
}
|
265
|
-
customElements.define("camera-status", nl);
|
266
|
-
function Zt(l, e, t) {
|
267
|
-
const s = l.slice();
|
268
|
-
return s[102] = e[t], s;
|
269
|
-
}
|
270
|
-
function pi(l) {
|
271
|
-
let e;
|
272
|
-
return {
|
273
|
-
c() {
|
274
|
-
e = h("idlive-face-capture"), e.hidden = !0, Lt(e, "mask_hidden", ""), Lt(e, "auto_capture_disabled", ""), Lt(e, "auto_close_disabled", "");
|
275
|
-
},
|
276
|
-
m(t, s) {
|
277
|
-
p(t, e, s), l[46](e);
|
278
|
-
},
|
279
|
-
p: G,
|
280
|
-
d(t) {
|
281
|
-
t && w(e), l[46](null);
|
282
|
-
}
|
283
|
-
};
|
284
|
-
}
|
285
|
-
function Qt(l) {
|
286
|
-
let e, t, s;
|
287
|
-
return {
|
288
|
-
c() {
|
289
|
-
e = h("video"), o(e, "id", "bry-cc-camera-video-tag"), o(e, "class", "invisible absolute -z-10"), e.playsInline = !0, e.muted = !0, e.autoplay = !0;
|
290
|
-
},
|
291
|
-
m(a, c) {
|
292
|
-
p(a, e, c), l[47](e), t || (s = [
|
293
|
-
se(
|
294
|
-
e,
|
295
|
-
"canplay",
|
296
|
-
/*canplay_handler*/
|
297
|
-
l[48]
|
298
|
-
),
|
299
|
-
se(
|
300
|
-
e,
|
301
|
-
"play",
|
302
|
-
/*play*/
|
303
|
-
l[1],
|
304
|
-
{ once: !0 }
|
305
|
-
)
|
306
|
-
], t = !0);
|
307
|
-
},
|
308
|
-
p: G,
|
309
|
-
d(a) {
|
310
|
-
a && w(e), l[47](null), t = !1, bt(s);
|
311
|
-
}
|
312
|
-
};
|
313
|
-
}
|
314
|
-
function gi(l) {
|
315
|
-
let e, t;
|
316
|
-
return {
|
317
|
-
c() {
|
318
|
-
e = Z("svg"), t = Z("path"), o(t, "fill", "currentColor"), o(t, "d", "M470.6 105.4c12.5 12.5 12.5 32.8 0 45.3l-256 256c-12.5 12.5-32.8 12.5-45.3 0l-128-128c-12.5-12.5-12.5-32.8 0-45.3s32.8-12.5 45.3 0L192 338.7l233.4-233.3c12.5-12.5 32.8-12.5 45.3 0z"), o(e, "class", "mt-[1px] ml-[.25em] overflow-visible"), o(e, "xmlns", "http://www.w3.org/2000/svg"), o(e, "width", "1em"), o(e, "height", "1em"), o(e, "viewBox", "0 0 512 512");
|
319
|
-
},
|
320
|
-
m(s, a) {
|
321
|
-
p(s, e, a), u(e, t);
|
322
|
-
},
|
323
|
-
d(s) {
|
324
|
-
s && w(e);
|
325
|
-
}
|
326
|
-
};
|
327
|
-
}
|
328
|
-
function vi(l) {
|
329
|
-
let e, t;
|
330
|
-
return {
|
331
|
-
c() {
|
332
|
-
e = Z("svg"), t = Z("path"), o(t, "fill", "currentColor"), o(t, "d", "M310.6 150.6c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L160 210.7L54.6 105.4c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3L114.7 256L9.4 361.4c-12.5 12.5-12.5 32.8 0 45.3s32.8 12.5 45.3 0L160 301.3l105.4 105.3c12.5 12.5 32.8 12.5 45.3 0s12.5-32.8 0-45.3L205.3 256l105.3-105.4z"), o(e, "class", "mt-[2px] ml-[.25em] overflow-visible"), o(e, "xmlns", "http://www.w3.org/2000/svg"), o(e, "width", "0.63em"), o(e, "height", "1em"), o(e, "viewBox", "0 0 320 512");
|
333
|
-
},
|
334
|
-
m(s, a) {
|
335
|
-
p(s, e, a), u(e, t);
|
336
|
-
},
|
337
|
-
d(s) {
|
338
|
-
s && w(e);
|
339
|
-
}
|
340
|
-
};
|
341
|
-
}
|
342
|
-
function wi(l) {
|
343
|
-
let e, t;
|
344
|
-
return {
|
345
|
-
c() {
|
346
|
-
e = Z("svg"), t = Z("path"), o(t, "fill", "currentColor"), o(t, "d", "M310.6 150.6c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L160 210.7L54.6 105.4c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3L114.7 256L9.4 361.4c-12.5 12.5-12.5 32.8 0 45.3s32.8 12.5 45.3 0L160 301.3l105.4 105.3c12.5 12.5 32.8 12.5 45.3 0s12.5-32.8 0-45.3L205.3 256l105.3-105.4z"), o(e, "class", "mt-[2px] ml-[.25em] overflow-visible"), o(e, "xmlns", "http://www.w3.org/2000/svg"), o(e, "width", "0.63em"), o(e, "height", "1em"), o(e, "viewBox", "0 0 320 512");
|
347
|
-
},
|
348
|
-
m(s, a) {
|
349
|
-
p(s, e, a), u(e, t);
|
350
|
-
},
|
351
|
-
d(s) {
|
352
|
-
s && w(e);
|
353
|
-
}
|
354
|
-
};
|
355
|
-
}
|
356
|
-
function ki(l) {
|
357
|
-
let e, t;
|
358
|
-
return {
|
359
|
-
c() {
|
360
|
-
e = Z("svg"), t = Z("path"), o(t, "fill", "currentColor"), o(t, "d", "M470.6 105.4c12.5 12.5 12.5 32.8 0 45.3l-256 256c-12.5 12.5-32.8 12.5-45.3 0l-128-128c-12.5-12.5-12.5-32.8 0-45.3s32.8-12.5 45.3 0L192 338.7l233.4-233.3c12.5-12.5 32.8-12.5 45.3 0z"), o(e, "class", "mt-[1px] ml-[.25em] overflow-visible"), o(e, "xmlns", "http://www.w3.org/2000/svg"), o(e, "width", "1em"), o(e, "height", "1em"), o(e, "viewBox", "0 0 512 512");
|
361
|
-
},
|
362
|
-
m(s, a) {
|
363
|
-
p(s, e, a), u(e, t);
|
364
|
-
},
|
365
|
-
d(s) {
|
366
|
-
s && w(e);
|
367
|
-
}
|
368
|
-
};
|
369
|
-
}
|
370
|
-
function Ci(l) {
|
371
|
-
let e = (
|
372
|
-
/*$_*/
|
373
|
-
l[20]("faceCollector.framing") + ""
|
374
|
-
), t;
|
375
|
-
return {
|
376
|
-
c() {
|
377
|
-
t = T(e);
|
378
|
-
},
|
379
|
-
m(s, a) {
|
380
|
-
p(s, t, a);
|
381
|
-
},
|
382
|
-
p(s, a) {
|
383
|
-
a[0] & /*$_*/
|
384
|
-
1048576 && e !== (e = /*$_*/
|
385
|
-
s[20]("faceCollector.framing") + "") && W(t, e);
|
386
|
-
},
|
387
|
-
d(s) {
|
388
|
-
s && w(t);
|
389
|
-
}
|
390
|
-
};
|
391
|
-
}
|
392
|
-
function Ei(l) {
|
393
|
-
let e;
|
394
|
-
return {
|
395
|
-
c() {
|
396
|
-
e = T("Framing");
|
397
|
-
},
|
398
|
-
m(t, s) {
|
399
|
-
p(t, e, s);
|
400
|
-
},
|
401
|
-
p: G,
|
402
|
-
d(t) {
|
403
|
-
t && w(e);
|
404
|
-
}
|
405
|
-
};
|
406
|
-
}
|
407
|
-
function Ri(l) {
|
408
|
-
let e, t;
|
409
|
-
return {
|
410
|
-
c() {
|
411
|
-
e = Z("svg"), t = Z("path"), o(t, "fill", "currentColor"), o(t, "d", "M310.6 150.6c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L160 210.7L54.6 105.4c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3L114.7 256L9.4 361.4c-12.5 12.5-12.5 32.8 0 45.3s32.8 12.5 45.3 0L160 301.3l105.4 105.3c12.5 12.5 32.8 12.5 45.3 0s12.5-32.8 0-45.3L205.3 256l105.3-105.4z"), o(e, "class", "mt-[2px] ml-[.25em] overflow-visible"), o(e, "xmlns", "http://www.w3.org/2000/svg"), o(e, "width", "0.63em"), o(e, "height", "1em"), o(e, "viewBox", "0 0 320 512");
|
412
|
-
},
|
413
|
-
m(s, a) {
|
414
|
-
p(s, e, a), u(e, t);
|
415
|
-
},
|
416
|
-
d(s) {
|
417
|
-
s && w(e);
|
418
|
-
}
|
419
|
-
};
|
420
|
-
}
|
421
|
-
function Li(l) {
|
422
|
-
let e, t;
|
423
|
-
return {
|
424
|
-
c() {
|
425
|
-
e = Z("svg"), t = Z("path"), o(t, "fill", "currentColor"), o(t, "d", "M470.6 105.4c12.5 12.5 12.5 32.8 0 45.3l-256 256c-12.5 12.5-32.8 12.5-45.3 0l-128-128c-12.5-12.5-12.5-32.8 0-45.3s32.8-12.5 45.3 0L192 338.7l233.4-233.3c12.5-12.5 32.8-12.5 45.3 0z"), o(e, "class", "mt-[1px] ml-[.25em] overflow-visible"), o(e, "xmlns", "http://www.w3.org/2000/svg"), o(e, "width", "1em"), o(e, "height", "1em"), o(e, "viewBox", "0 0 512 512");
|
426
|
-
},
|
427
|
-
m(s, a) {
|
428
|
-
p(s, e, a), u(e, t);
|
429
|
-
},
|
430
|
-
d(s) {
|
431
|
-
s && w(e);
|
432
|
-
}
|
433
|
-
};
|
434
|
-
}
|
435
|
-
function Xt(l) {
|
436
|
-
let e, t, s, a, c;
|
437
|
-
function d(f, g) {
|
438
|
-
return (
|
439
|
-
/*$isLoading*/
|
440
|
-
f[33] ? Pi : yi
|
441
|
-
);
|
442
|
-
}
|
443
|
-
let m = d(l), n = m(l);
|
444
|
-
return {
|
445
|
-
c() {
|
446
|
-
e = h("slot"), t = h("div"), s = h("img"), c = L(), n.c(), dt(s.src, a = ol) || o(s, "src", a), o(s, "alt", "loading gif"), o(s, "class", "m-auto h-[10em] lg:h-[12em]"), o(t, "class", "translate-y-1/3 md:translate-y-1/4 xl:translate-y-1/2"), o(e, "name", "obtaining-photo-gif"), o(e, "class", "block h-[17em] lg:h-[21.6em] xl:h-[30em]");
|
447
|
-
},
|
448
|
-
m(f, g) {
|
449
|
-
p(f, e, g), u(e, t), u(t, s), u(t, c), n.m(t, null);
|
450
|
-
},
|
451
|
-
p(f, g) {
|
452
|
-
m === (m = d(f)) && n ? n.p(f, g) : (n.d(1), n = m(f), n && (n.c(), n.m(t, null)));
|
453
|
-
},
|
454
|
-
d(f) {
|
455
|
-
f && w(e), n.d();
|
456
|
-
}
|
457
|
-
};
|
458
|
-
}
|
459
|
-
function yi(l) {
|
460
|
-
let e, t = (
|
461
|
-
/*$_*/
|
462
|
-
l[20]("faceCollector.obtainingPicture") + ""
|
463
|
-
), s;
|
464
|
-
return {
|
465
|
-
c() {
|
466
|
-
e = h("span"), s = T(t), o(e, "class", "2xl:text-2xl lg:text-2xl text-md block p-2 m-auto text-center");
|
467
|
-
},
|
468
|
-
m(a, c) {
|
469
|
-
p(a, e, c), u(e, s);
|
470
|
-
},
|
471
|
-
p(a, c) {
|
472
|
-
c[0] & /*$_*/
|
473
|
-
1048576 && t !== (t = /*$_*/
|
474
|
-
a[20]("faceCollector.obtainingPicture") + "") && W(s, t);
|
475
|
-
},
|
476
|
-
d(a) {
|
477
|
-
a && w(e);
|
478
|
-
}
|
479
|
-
};
|
480
|
-
}
|
481
|
-
function Pi(l) {
|
482
|
-
let e;
|
483
|
-
return {
|
484
|
-
c() {
|
485
|
-
e = h("span"), e.textContent = "Obtaining photo...", o(e, "class", "2xl:text-2xl lg:text-2xl text-md block p-2 m-auto text-center");
|
486
|
-
},
|
487
|
-
m(t, s) {
|
488
|
-
p(t, e, s);
|
489
|
-
},
|
490
|
-
p: G,
|
491
|
-
d(t) {
|
492
|
-
t && w(e);
|
493
|
-
}
|
494
|
-
};
|
495
|
-
}
|
496
|
-
function Jt(l) {
|
497
|
-
let e, t, s, a, c;
|
498
|
-
function d(f, g) {
|
499
|
-
return (
|
500
|
-
/*$isLoading*/
|
501
|
-
f[33] ? Ii : Oi
|
502
|
-
);
|
503
|
-
}
|
504
|
-
let m = d(l), n = m(l);
|
505
|
-
return {
|
506
|
-
c() {
|
507
|
-
e = h("slot"), t = h("div"), s = h("img"), c = L(), n.c(), dt(s.src, a = ol) || o(s, "src", a), o(s, "alt", "loading gif"), o(s, "class", "m-auto h-[10em] lg:h-[12em]"), o(t, "class", "translate-y-1/3 md:translate-y-1/4 xl:translate-y-1/2"), o(e, "name", "loading-camera-gif"), o(e, "class", "block h-[17em] lg:h-[21.6em] xl:h-[30em]");
|
508
|
-
},
|
509
|
-
m(f, g) {
|
510
|
-
p(f, e, g), u(e, t), u(t, s), u(t, c), n.m(t, null);
|
511
|
-
},
|
512
|
-
p(f, g) {
|
513
|
-
m === (m = d(f)) && n ? n.p(f, g) : (n.d(1), n = m(f), n && (n.c(), n.m(t, null)));
|
514
|
-
},
|
515
|
-
d(f) {
|
516
|
-
f && w(e), n.d();
|
517
|
-
}
|
518
|
-
};
|
519
|
-
}
|
520
|
-
function Oi(l) {
|
521
|
-
let e, t = (
|
522
|
-
/*$_*/
|
523
|
-
l[20]("faceCollector.initiatingCamera") + ""
|
524
|
-
), s;
|
525
|
-
return {
|
526
|
-
c() {
|
527
|
-
e = h("span"), s = T(t), o(e, "class", "2xl:text-2xl lg:text-2xl text-md block p-2 m-auto text-center");
|
528
|
-
},
|
529
|
-
m(a, c) {
|
530
|
-
p(a, e, c), u(e, s);
|
531
|
-
},
|
532
|
-
p(a, c) {
|
533
|
-
c[0] & /*$_*/
|
534
|
-
1048576 && t !== (t = /*$_*/
|
535
|
-
a[20]("faceCollector.initiatingCamera") + "") && W(s, t);
|
536
|
-
},
|
537
|
-
d(a) {
|
538
|
-
a && w(e);
|
539
|
-
}
|
540
|
-
};
|
541
|
-
}
|
542
|
-
function Ii(l) {
|
543
|
-
let e;
|
544
|
-
return {
|
545
|
-
c() {
|
546
|
-
e = h("span"), e.textContent = "Loading camera...", o(e, "class", "2xl:text-2xl lg:text-2xl text-md block p-2 m-auto text-center");
|
547
|
-
},
|
548
|
-
m(t, s) {
|
549
|
-
p(t, e, s);
|
550
|
-
},
|
551
|
-
p: G,
|
552
|
-
d(t) {
|
553
|
-
t && w(e);
|
554
|
-
}
|
555
|
-
};
|
556
|
-
}
|
557
|
-
function Ai(l) {
|
558
|
-
let e, t, s = (
|
559
|
-
/*$_*/
|
560
|
-
l[20]("faceCollector.finish") + ""
|
561
|
-
), a, c, d, m, n = (
|
562
|
-
/*$_*/
|
563
|
-
l[20]("faceCollector.retakePhoto") + ""
|
564
|
-
), f, g, E;
|
565
|
-
return {
|
566
|
-
c() {
|
567
|
-
e = h("div"), t = h("button"), a = T(s), d = L(), m = h("button"), f = T(n), t.disabled = c = /*$justification*/
|
568
|
-
l[25].length === 0, o(t, "class", "ce-dui-btn ce-dui-btn-primary ce-dui-btn-block flex-shrink"), o(m, "id", "bry-cc-retake-button"), o(m, "class", "ce-dui-btn ce-dui-btn-block ce-dui-btn-outline flex-shrink"), o(e, "class", "ce-dui-btn-group flex");
|
569
|
-
},
|
570
|
-
m(b, r) {
|
571
|
-
p(b, e, r), u(e, t), u(t, a), u(e, d), u(e, m), u(m, f), g || (E = [
|
572
|
-
se(
|
573
|
-
t,
|
574
|
-
"click",
|
575
|
-
/*click_handler_1*/
|
576
|
-
l[57]
|
577
|
-
),
|
578
|
-
se(
|
579
|
-
m,
|
580
|
-
"click",
|
581
|
-
/*click_handler_2*/
|
582
|
-
l[58]
|
583
|
-
)
|
584
|
-
], g = !0);
|
585
|
-
},
|
586
|
-
p(b, r) {
|
587
|
-
r[0] & /*$_*/
|
588
|
-
1048576 && s !== (s = /*$_*/
|
589
|
-
b[20]("faceCollector.finish") + "") && W(a, s), r[0] & /*$justification*/
|
590
|
-
33554432 && c !== (c = /*$justification*/
|
591
|
-
b[25].length === 0) && (t.disabled = c), r[0] & /*$_*/
|
592
|
-
1048576 && n !== (n = /*$_*/
|
593
|
-
b[20]("faceCollector.retakePhoto") + "") && W(f, n);
|
594
|
-
},
|
595
|
-
d(b) {
|
596
|
-
b && w(e), g = !1, bt(E);
|
597
|
-
}
|
598
|
-
};
|
599
|
-
}
|
600
|
-
function Si(l) {
|
601
|
-
let e, t, s, a;
|
602
|
-
function c(n, f) {
|
603
|
-
return (
|
604
|
-
/*$isLoading*/
|
605
|
-
n[33] ? Di : Ti
|
606
|
-
);
|
607
|
-
}
|
608
|
-
let d = c(l), m = d(l);
|
609
|
-
return {
|
610
|
-
c() {
|
611
|
-
e = h("button"), m.c(), o(e, "id", "bry-cc-capture-btn"), e.disabled = t = !/*$faceFound*/
|
612
|
-
l[31] && /*$enableFaceApi*/
|
613
|
-
l[28] || !/*$ready*/
|
614
|
-
l[29] && !/*$enableFaceApi*/
|
615
|
-
l[28], o(e, "class", "ce-dui-btn ce-dui-btn-block ce-dui-btn-primary text-xl");
|
616
|
-
},
|
617
|
-
m(n, f) {
|
618
|
-
p(n, e, f), m.m(e, null), s || (a = se(
|
619
|
-
e,
|
620
|
-
"click",
|
621
|
-
/*click_handler*/
|
622
|
-
l[56]
|
623
|
-
), s = !0);
|
624
|
-
},
|
625
|
-
p(n, f) {
|
626
|
-
d === (d = c(n)) && m ? m.p(n, f) : (m.d(1), m = d(n), m && (m.c(), m.m(e, null))), f[0] & /*$enableFaceApi, $ready*/
|
627
|
-
805306368 | f[1] & /*$faceFound*/
|
628
|
-
1 && t !== (t = !/*$faceFound*/
|
629
|
-
n[31] && /*$enableFaceApi*/
|
630
|
-
n[28] || !/*$ready*/
|
631
|
-
n[29] && !/*$enableFaceApi*/
|
632
|
-
n[28]) && (e.disabled = t);
|
633
|
-
},
|
634
|
-
d(n) {
|
635
|
-
n && w(e), m.d(), s = !1, a();
|
636
|
-
}
|
637
|
-
};
|
638
|
-
}
|
639
|
-
function Ti(l) {
|
640
|
-
let e = (
|
641
|
-
/*$_*/
|
642
|
-
l[20]("faceCollector.takePicture") + ""
|
643
|
-
), t;
|
644
|
-
return {
|
645
|
-
c() {
|
646
|
-
t = T(e);
|
647
|
-
},
|
648
|
-
m(s, a) {
|
649
|
-
p(s, t, a);
|
650
|
-
},
|
651
|
-
p(s, a) {
|
652
|
-
a[0] & /*$_*/
|
653
|
-
1048576 && e !== (e = /*$_*/
|
654
|
-
s[20]("faceCollector.takePicture") + "") && W(t, e);
|
655
|
-
},
|
656
|
-
d(s) {
|
657
|
-
s && w(t);
|
658
|
-
}
|
659
|
-
};
|
660
|
-
}
|
661
|
-
function Di(l) {
|
662
|
-
let e;
|
663
|
-
return {
|
664
|
-
c() {
|
665
|
-
e = T("Take picture");
|
666
|
-
},
|
667
|
-
m(t, s) {
|
668
|
-
p(t, e, s);
|
669
|
-
},
|
670
|
-
p: G,
|
671
|
-
d(t) {
|
672
|
-
t && w(e);
|
673
|
-
}
|
674
|
-
};
|
675
|
-
}
|
676
|
-
function xi(l) {
|
677
|
-
let e, t;
|
678
|
-
return e = new nl({ props: { handler: (
|
679
|
-
/*func*/
|
680
|
-
l[67]
|
681
|
-
) } }), {
|
682
|
-
c() {
|
683
|
-
It(e.$$.fragment);
|
684
|
-
},
|
685
|
-
m(s, a) {
|
686
|
-
At(e, s, a), t = !0;
|
687
|
-
},
|
688
|
-
p(s, a) {
|
689
|
-
const c = {};
|
690
|
-
a[0] & /*capturing*/
|
691
|
-
8192 && (c.handler = /*func*/
|
692
|
-
s[67]), e.$set(c);
|
693
|
-
},
|
694
|
-
i(s) {
|
695
|
-
t || (Fe(e.$$.fragment, s), t = !0);
|
696
|
-
},
|
697
|
-
o(s) {
|
698
|
-
Ne(e.$$.fragment, s), t = !1;
|
699
|
-
},
|
700
|
-
d(s) {
|
701
|
-
St(e, s);
|
702
|
-
}
|
703
|
-
};
|
704
|
-
}
|
705
|
-
function Mi(l) {
|
706
|
-
let e, t, s, a, c, d, m, n, f;
|
707
|
-
const g = [
|
708
|
-
Hi,
|
709
|
-
Bi,
|
710
|
-
Wi,
|
711
|
-
Fi,
|
712
|
-
Ni
|
713
|
-
], E = [];
|
714
|
-
function b(r, _) {
|
715
|
-
return (
|
716
|
-
/*$captured*/
|
717
|
-
r[18] ? (
|
718
|
-
/*$unconformitiesStore*/
|
719
|
-
r[23].isLoading ? 1 : (
|
720
|
-
/*$requestResult*/
|
721
|
-
r[21] !== J.OK ? 2 : (
|
722
|
-
/*$saved*/
|
723
|
-
r[24] ? 4 : 3
|
724
|
-
)
|
725
|
-
)
|
726
|
-
) : 0
|
727
|
-
);
|
728
|
-
}
|
729
|
-
return d = b(l), m = E[d] = g[d](l), {
|
730
|
-
c() {
|
731
|
-
e = h("div"), t = h("img"), c = L(), m.c(), o(t, "class", "m-auto col-start-1 col-end-1 max-h-[23.2em]"), dt(t.src, s = /*$dataTypePrefix*/
|
732
|
-
l[27] + "," + /*$image*/
|
733
|
-
l[26]) || o(t, "src", s), t.hidden = a = !/*$captured*/
|
734
|
-
l[18] || !/*$showFaceWhileValidating*/
|
735
|
-
l[34] && /*$unconformitiesStore*/
|
736
|
-
l[23].isLoading, o(t, "alt", ""), o(e, "class", n = "grid-cols-1 grid-rows-2 sm:grid-cols-2 sm:grid-rows-1 gap-[.5em] " + (!/*$showFaceWhileValidating*/
|
737
|
-
l[34] && /*$unconformitiesStore*/
|
738
|
-
l[23].isLoading ? "absolute -translate-y-1/2 -translate-x-1/2 top-1/2 left-1/2 overflow-visible" : "grid m-[1em] overflow-hidden"));
|
739
|
-
},
|
740
|
-
m(r, _) {
|
741
|
-
p(r, e, _), u(e, t), u(e, c), E[d].m(e, null), f = !0;
|
742
|
-
},
|
743
|
-
p(r, _) {
|
744
|
-
(!f || _[0] & /*$dataTypePrefix, $image*/
|
745
|
-
201326592 && !dt(t.src, s = /*$dataTypePrefix*/
|
746
|
-
r[27] + "," + /*$image*/
|
747
|
-
r[26])) && o(t, "src", s), (!f || _[0] & /*$captured, $unconformitiesStore*/
|
748
|
-
8650752 | _[1] & /*$showFaceWhileValidating*/
|
749
|
-
8 && a !== (a = !/*$captured*/
|
750
|
-
r[18] || !/*$showFaceWhileValidating*/
|
751
|
-
r[34] && /*$unconformitiesStore*/
|
752
|
-
r[23].isLoading)) && (t.hidden = a);
|
753
|
-
let y = d;
|
754
|
-
d = b(r), d === y ? E[d].p(r, _) : (sl(), Ne(E[y], 1, 1, () => {
|
755
|
-
E[y] = null;
|
756
|
-
}), al(), m = E[d], m ? m.p(r, _) : (m = E[d] = g[d](r), m.c()), Fe(m, 1), m.m(e, null)), (!f || _[0] & /*$unconformitiesStore*/
|
757
|
-
8388608 | _[1] & /*$showFaceWhileValidating*/
|
758
|
-
8 && n !== (n = "grid-cols-1 grid-rows-2 sm:grid-cols-2 sm:grid-rows-1 gap-[.5em] " + (!/*$showFaceWhileValidating*/
|
759
|
-
r[34] && /*$unconformitiesStore*/
|
760
|
-
r[23].isLoading ? "absolute -translate-y-1/2 -translate-x-1/2 top-1/2 left-1/2 overflow-visible" : "grid m-[1em] overflow-hidden"))) && o(e, "class", n);
|
761
|
-
},
|
762
|
-
i(r) {
|
763
|
-
f || (Fe(m), f = !0);
|
764
|
-
},
|
765
|
-
o(r) {
|
766
|
-
Ne(m), f = !1;
|
767
|
-
},
|
768
|
-
d(r) {
|
769
|
-
r && w(e), E[d].d();
|
770
|
-
}
|
771
|
-
};
|
772
|
-
}
|
773
|
-
function Ni(l) {
|
774
|
-
let e, t, s = (
|
775
|
-
/*$_*/
|
776
|
-
l[20]("faceCollector.captured") + ""
|
777
|
-
), a, c, d, m, n, f = (
|
778
|
-
/*$_*/
|
779
|
-
l[20]("faceCollector.retakePhoto") + ""
|
780
|
-
), g, E, b = Pt(ni).faceStrategy !== ri.DISABLED, r, _, y, O = (
|
781
|
-
/*$unconformitiesStore*/
|
782
|
-
l[23].unconformities.length !== 0 && Gt(l)
|
783
|
-
), R = b && Ui();
|
784
|
-
return {
|
785
|
-
c() {
|
786
|
-
e = h("div"), t = h("h1"), a = T(s), c = L(), O && O.c(), d = L(), m = h("div"), n = h("button"), g = T(f), E = L(), R && R.c(), o(t, "class", "text-3xl font-bold pb-[1em] transition-opacity"), o(n, "id", "bry-cc-retake-button"), o(n, "class", "ce-dui-btn ce-dui-btn-block flex-shrink text-base"), o(m, "class", "flex flex-row"), zt(m, "ce-dui-btn-group", !/*$exportButtonDisabled*/
|
787
|
-
l[35]);
|
788
|
-
},
|
789
|
-
m(C, U) {
|
790
|
-
p(C, e, U), u(e, t), u(t, a), u(e, c), O && O.m(e, null), u(e, d), u(e, m), u(m, n), u(n, g), u(m, E), R && R.m(m, null), r = !0, _ || (y = se(
|
791
|
-
n,
|
792
|
-
"click",
|
793
|
-
/*click_handler_7*/
|
794
|
-
l[66]
|
795
|
-
), _ = !0);
|
796
|
-
},
|
797
|
-
p(C, U) {
|
798
|
-
(!r || U[0] & /*$_*/
|
799
|
-
1048576) && s !== (s = /*$_*/
|
800
|
-
C[20]("faceCollector.captured") + "") && W(a, s), /*$unconformitiesStore*/
|
801
|
-
C[23].unconformities.length !== 0 ? O ? O.p(C, U) : (O = Gt(C), O.c(), O.m(e, d)) : O && (O.d(1), O = null), (!r || U[0] & /*$_*/
|
802
|
-
1048576) && f !== (f = /*$_*/
|
803
|
-
C[20]("faceCollector.retakePhoto") + "") && W(g, f), (!r || U[1] & /*$exportButtonDisabled*/
|
804
|
-
16) && zt(m, "ce-dui-btn-group", !/*$exportButtonDisabled*/
|
805
|
-
C[35]);
|
806
|
-
},
|
807
|
-
i(C) {
|
808
|
-
r || (Fe(R), r = !0);
|
809
|
-
},
|
810
|
-
o(C) {
|
811
|
-
Ne(R), r = !1;
|
812
|
-
},
|
813
|
-
d(C) {
|
814
|
-
C && w(e), O && O.d(), R && R.d(), _ = !1, y();
|
815
|
-
}
|
816
|
-
};
|
817
|
-
}
|
818
|
-
function Fi(l) {
|
819
|
-
let e, t, s = (
|
820
|
-
/*$_*/
|
821
|
-
l[20]("faceCollector.unconformities") + ""
|
822
|
-
), a, c, d, m, n, f, g, E = (
|
823
|
-
/*$_*/
|
824
|
-
l[20]("faceCollector.provideAReasonForTheLowQualityCapture") + ""
|
825
|
-
), b, r, _, y, O, R, C, U, _e = (
|
826
|
-
/*$_*/
|
827
|
-
l[20]("faceCollector.thisInformationIsRequired") + ""
|
828
|
-
), ce, Q, ae, j, Oe, ue = (
|
829
|
-
/*$unconformitiesStore*/
|
830
|
-
l[23].unconformities
|
831
|
-
), M = [];
|
832
|
-
for (let D = 0; D < ue.length; D += 1)
|
833
|
-
M[D] = Yt(Zt(l, ue, D));
|
834
|
-
let V = (
|
835
|
-
/*$captured*/
|
836
|
-
l[18] && $t(l)
|
837
|
-
);
|
838
|
-
return {
|
839
|
-
c() {
|
840
|
-
e = h("div"), t = h("h1"), a = T(s), c = L(), d = h("div");
|
841
|
-
for (let D = 0; D < M.length; D += 1)
|
842
|
-
M[D].c();
|
843
|
-
m = L(), n = h("div"), f = h("label"), g = h("span"), b = T(E), r = L(), _ = h("textarea"), O = L(), R = h("label"), C = h("span"), U = T("("), ce = T(_e), Q = T(")"), ae = L(), V && V.c(), o(t, "class", "text-3xl font-bold pb-[1em] transition-opacity"), o(d, "class", "flex flex-wrap"), o(g, "class", "ce-dui-label-text text-base"), o(f, "class", "ce-dui-label"), o(f, "for", "justification"), o(_, "contenteditable", ""), o(_, "id", "justification"), o(_, "class", "ce-dui-textarea ce-dui-textarea-bordered h-[6em] text-base"), o(_, "placeholder", y = /*$_*/
|
844
|
-
l[20]("faceCollector.yourJustification")), o(C, "class", "ce-dui-label-text-alt text-base"), o(R, "class", "ce-dui-label"), o(R, "for", "justification"), o(n, "class", "ce-dui-form-control mt-[2.5em]");
|
845
|
-
},
|
846
|
-
m(D, te) {
|
847
|
-
p(D, e, te), u(e, t), u(t, a), u(e, c), u(e, d);
|
848
|
-
for (let x = 0; x < M.length; x += 1)
|
849
|
-
M[x] && M[x].m(d, null);
|
850
|
-
u(e, m), u(e, n), u(n, f), u(f, g), u(g, b), u(n, r), u(n, _), mt(
|
851
|
-
_,
|
852
|
-
/*$justification*/
|
853
|
-
l[25]
|
854
|
-
), u(n, O), u(n, R), u(R, C), u(C, U), u(C, ce), u(C, Q), u(e, ae), V && V.m(e, null), j || (Oe = se(
|
855
|
-
_,
|
856
|
-
"input",
|
857
|
-
/*textarea_input_handler*/
|
858
|
-
l[62]
|
859
|
-
), j = !0);
|
860
|
-
},
|
861
|
-
p(D, te) {
|
862
|
-
if (te[0] & /*$_*/
|
863
|
-
1048576 && s !== (s = /*$_*/
|
864
|
-
D[20]("faceCollector.unconformities") + "") && W(a, s), te[0] & /*$unconformitiesStore*/
|
865
|
-
8388608) {
|
866
|
-
ue = /*$unconformitiesStore*/
|
867
|
-
D[23].unconformities;
|
868
|
-
let x;
|
869
|
-
for (x = 0; x < ue.length; x += 1) {
|
870
|
-
const be = Zt(D, ue, x);
|
871
|
-
M[x] ? M[x].p(be, te) : (M[x] = Yt(be), M[x].c(), M[x].m(d, null));
|
872
|
-
}
|
873
|
-
for (; x < M.length; x += 1)
|
874
|
-
M[x].d(1);
|
875
|
-
M.length = ue.length;
|
876
|
-
}
|
877
|
-
te[0] & /*$_*/
|
878
|
-
1048576 && E !== (E = /*$_*/
|
879
|
-
D[20]("faceCollector.provideAReasonForTheLowQualityCapture") + "") && W(b, E), te[0] & /*$_*/
|
880
|
-
1048576 && y !== (y = /*$_*/
|
881
|
-
D[20]("faceCollector.yourJustification")) && o(_, "placeholder", y), te[0] & /*$justification*/
|
882
|
-
33554432 && mt(
|
883
|
-
_,
|
884
|
-
/*$justification*/
|
885
|
-
D[25]
|
886
|
-
), te[0] & /*$_*/
|
887
|
-
1048576 && _e !== (_e = /*$_*/
|
888
|
-
D[20]("faceCollector.thisInformationIsRequired") + "") && W(ce, _e), /*$captured*/
|
889
|
-
D[18] ? V ? V.p(D, te) : (V = $t(D), V.c(), V.m(e, null)) : V && (V.d(1), V = null);
|
890
|
-
},
|
891
|
-
i: G,
|
892
|
-
o: G,
|
893
|
-
d(D) {
|
894
|
-
D && w(e), ci(M, D), V && V.d(), j = !1, Oe();
|
895
|
-
}
|
896
|
-
};
|
897
|
-
}
|
898
|
-
function Wi(l) {
|
899
|
-
let e, t, s, a, c, d = (
|
900
|
-
/*$_*/
|
901
|
-
l[20]("faceCollector.finish") + ""
|
902
|
-
), m, n, f, g = (
|
903
|
-
/*$_*/
|
904
|
-
l[20]("faceCollector.retakePhoto") + ""
|
905
|
-
), E, b, r;
|
906
|
-
function _(R, C) {
|
907
|
-
return C[0] & /*$requestResult, $rejectOnFailLiveness*/
|
908
|
-
6291456 && (t = null), /*$requestResult*/
|
909
|
-
R[21] === J.LIVENESS_DETECTION_FAILURE || /*$requestResult*/
|
910
|
-
R[21] === J.UNKNOWN_LIVENESS_ERROR ? zi : (t == null && (t = !!/*$requestResult*/
|
911
|
-
(R[21] === J.LOW_LIVENESS_SCORE && q() && /*$rejectOnFailLiveness*/
|
912
|
-
R[22])), t ? qi : (
|
913
|
-
/*$requestResult*/
|
914
|
-
R[21] === J.TEMPLATE_EXTRACTION_ERROR || /*$requestResult*/
|
915
|
-
R[21] === J.UNKNOWN_TEMPLATE_EXTRACTION_ERROR ? ji : (
|
916
|
-
/*$requestResult*/
|
917
|
-
R[21] === J.UNABLE_TO_COMMUNICATE_WITH_TEMPLATE_EXTRACTION_SERVICE ? Ki : Vi
|
918
|
-
)
|
919
|
-
));
|
920
|
-
}
|
921
|
-
let y = _(l, [-1, -1, -1, -1]), O = y(l);
|
922
|
-
return {
|
923
|
-
c() {
|
924
|
-
e = h("div"), O.c(), s = L(), a = h("div"), c = h("button"), m = T(d), n = L(), f = h("button"), E = T(g), c.disabled = !0, o(c, "class", "ce-dui-btn ce-dui-btn-primary ce-dui-btn-block flex-shrink"), o(f, "id", "bry-cc-retake-button"), o(f, "class", "ce-dui-btn ce-dui-btn-block ce-dui-btn-outline flex-shrink"), o(a, "class", "ce-dui-btn-group flex"), o(e, "class", "flex flex-col justify-between");
|
925
|
-
},
|
926
|
-
m(R, C) {
|
927
|
-
p(R, e, C), O.m(e, null), u(e, s), u(e, a), u(a, c), u(c, m), u(a, n), u(a, f), u(f, E), b || (r = [
|
928
|
-
se(
|
929
|
-
c,
|
930
|
-
"click",
|
931
|
-
/*click_handler_3*/
|
932
|
-
l[60]
|
933
|
-
),
|
934
|
-
se(
|
935
|
-
f,
|
936
|
-
"click",
|
937
|
-
/*click_handler_4*/
|
938
|
-
l[61]
|
939
|
-
)
|
940
|
-
], b = !0);
|
941
|
-
},
|
942
|
-
p(R, C) {
|
943
|
-
y === (y = _(R, C)) && O ? O.p(R, C) : (O.d(1), O = y(R), O && (O.c(), O.m(e, s))), C[0] & /*$_*/
|
944
|
-
1048576 && d !== (d = /*$_*/
|
945
|
-
R[20]("faceCollector.finish") + "") && W(m, d), C[0] & /*$_*/
|
946
|
-
1048576 && g !== (g = /*$_*/
|
947
|
-
R[20]("faceCollector.retakePhoto") + "") && W(E, g);
|
948
|
-
},
|
949
|
-
i: G,
|
950
|
-
o: G,
|
951
|
-
d(R) {
|
952
|
-
R && w(e), O.d(), b = !1, bt(r);
|
953
|
-
}
|
954
|
-
};
|
955
|
-
}
|
956
|
-
function Bi(l) {
|
957
|
-
let e, t, s = (
|
958
|
-
/*$_*/
|
959
|
-
l[20]("faceCollector.validating") + ""
|
960
|
-
), a, c, d;
|
961
|
-
return {
|
962
|
-
c() {
|
963
|
-
e = h("div"), t = h("h1"), a = T(s), c = L(), d = h("div"), o(t, "class", "inline-block text-3xl font-bold pb-[1em] transition-opacity"), o(d, "class", "ml-6 inline-block dot-typing"), o(e, "class", "min-w-[200px]");
|
964
|
-
},
|
965
|
-
m(m, n) {
|
966
|
-
p(m, e, n), u(e, t), u(t, a), u(e, c), u(e, d);
|
967
|
-
},
|
968
|
-
p(m, n) {
|
969
|
-
n[0] & /*$_*/
|
970
|
-
1048576 && s !== (s = /*$_*/
|
971
|
-
m[20]("faceCollector.validating") + "") && W(a, s);
|
972
|
-
},
|
973
|
-
i: G,
|
974
|
-
o: G,
|
975
|
-
d(m) {
|
976
|
-
m && w(e);
|
977
|
-
}
|
978
|
-
};
|
979
|
-
}
|
980
|
-
function Hi(l) {
|
981
|
-
let e;
|
982
|
-
return {
|
983
|
-
c() {
|
984
|
-
e = h("div"), o(e, "class", "");
|
985
|
-
},
|
986
|
-
m(t, s) {
|
987
|
-
p(t, e, s);
|
988
|
-
},
|
989
|
-
p: G,
|
990
|
-
i: G,
|
991
|
-
o: G,
|
992
|
-
d(t) {
|
993
|
-
t && w(e);
|
994
|
-
}
|
995
|
-
};
|
996
|
-
}
|
997
|
-
function Gt(l) {
|
998
|
-
let e, t, s = (
|
999
|
-
/*$_*/
|
1000
|
-
l[20]("faceCollector.justification") + ""
|
1001
|
-
), a, c, d, m, n;
|
1002
|
-
return {
|
1003
|
-
c() {
|
1004
|
-
e = h("label"), t = h("span"), a = T(s), c = L(), d = h("textarea"), o(t, "class", "ce-dui-label-text text-base"), o(e, "class", "ce-dui-label"), o(e, "for", "justification"), o(d, "contenteditable", ""), o(d, "id", "justification"), o(d, "class", "ce-dui-textarea ce-dui-textarea-bordered textarea-ghost h-[6em] w-full text-base");
|
1005
|
-
},
|
1006
|
-
m(f, g) {
|
1007
|
-
p(f, e, g), u(e, t), u(t, a), p(f, c, g), p(f, d, g), mt(
|
1008
|
-
d,
|
1009
|
-
/*$justification*/
|
1010
|
-
l[25]
|
1011
|
-
), m || (n = se(
|
1012
|
-
d,
|
1013
|
-
"input",
|
1014
|
-
/*textarea_input_handler_1*/
|
1015
|
-
l[65]
|
1016
|
-
), m = !0);
|
1017
|
-
},
|
1018
|
-
p(f, g) {
|
1019
|
-
g[0] & /*$_*/
|
1020
|
-
1048576 && s !== (s = /*$_*/
|
1021
|
-
f[20]("faceCollector.justification") + "") && W(a, s), g[0] & /*$justification*/
|
1022
|
-
33554432 && mt(
|
1023
|
-
d,
|
1024
|
-
/*$justification*/
|
1025
|
-
f[25]
|
1026
|
-
);
|
1027
|
-
},
|
1028
|
-
d(f) {
|
1029
|
-
f && w(e), f && w(c), f && w(d), m = !1, n();
|
1030
|
-
}
|
1031
|
-
};
|
1032
|
-
}
|
1033
|
-
function Ui(l) {
|
1034
|
-
let e, t;
|
1035
|
-
return e = new ui({
|
1036
|
-
props: { cssClass: "ce-dui-btn-block flex-shrink" }
|
1037
|
-
}), {
|
1038
|
-
c() {
|
1039
|
-
It(e.$$.fragment);
|
1040
|
-
},
|
1041
|
-
m(s, a) {
|
1042
|
-
At(e, s, a), t = !0;
|
1043
|
-
},
|
1044
|
-
i(s) {
|
1045
|
-
t || (Fe(e.$$.fragment, s), t = !0);
|
1046
|
-
},
|
1047
|
-
o(s) {
|
1048
|
-
Ne(e.$$.fragment, s), t = !1;
|
1049
|
-
},
|
1050
|
-
d(s) {
|
1051
|
-
St(e, s);
|
1052
|
-
}
|
1053
|
-
};
|
1054
|
-
}
|
1055
|
-
function Yt(l) {
|
1056
|
-
let e, t = (
|
1057
|
-
/*unconformity*/
|
1058
|
-
l[102] + ""
|
1059
|
-
), s, a;
|
1060
|
-
return {
|
1061
|
-
c() {
|
1062
|
-
e = h("div"), s = T(t), a = L(), o(e, "class", "ce-dui-badge ce-dui-badge-lg h-[2em] ce-dui-badge-error text-xl pb-[.25em] m-[.5em]");
|
1063
|
-
},
|
1064
|
-
m(c, d) {
|
1065
|
-
p(c, e, d), u(e, s), u(e, a);
|
1066
|
-
},
|
1067
|
-
p(c, d) {
|
1068
|
-
d[0] & /*$unconformitiesStore*/
|
1069
|
-
8388608 && t !== (t = /*unconformity*/
|
1070
|
-
c[102] + "") && W(s, t);
|
1071
|
-
},
|
1072
|
-
d(c) {
|
1073
|
-
c && w(e);
|
1074
|
-
}
|
1075
|
-
};
|
1076
|
-
}
|
1077
|
-
function $t(l) {
|
1078
|
-
let e, t, s = (
|
1079
|
-
/*$_*/
|
1080
|
-
l[20]("faceCollector.finish") + ""
|
1081
|
-
), a, c, d, m, n = (
|
1082
|
-
/*$_*/
|
1083
|
-
l[20]("faceCollector.retakePhoto") + ""
|
1084
|
-
), f, g, E;
|
1085
|
-
return {
|
1086
|
-
c() {
|
1087
|
-
e = h("div"), t = h("button"), a = T(s), d = L(), m = h("button"), f = T(n), t.disabled = c = /*$justification*/
|
1088
|
-
l[25].length === 0, o(t, "class", "ce-dui-btn ce-dui-btn-primary ce-dui-btn-block flex-shrink text-base"), o(m, "id", "bry-cc-retake-button"), o(m, "class", "ce-dui-btn ce-dui-btn-block ce-dui-btn-outline flex-shrink text-base"), o(e, "class", "ce-dui-btn-group flex");
|
1089
|
-
},
|
1090
|
-
m(b, r) {
|
1091
|
-
p(b, e, r), u(e, t), u(t, a), u(e, d), u(e, m), u(m, f), g || (E = [
|
1092
|
-
se(
|
1093
|
-
t,
|
1094
|
-
"click",
|
1095
|
-
/*click_handler_5*/
|
1096
|
-
l[63]
|
1097
|
-
),
|
1098
|
-
se(
|
1099
|
-
m,
|
1100
|
-
"click",
|
1101
|
-
/*click_handler_6*/
|
1102
|
-
l[64]
|
1103
|
-
)
|
1104
|
-
], g = !0);
|
1105
|
-
},
|
1106
|
-
p(b, r) {
|
1107
|
-
r[0] & /*$_*/
|
1108
|
-
1048576 && s !== (s = /*$_*/
|
1109
|
-
b[20]("faceCollector.finish") + "") && W(a, s), r[0] & /*$justification*/
|
1110
|
-
33554432 && c !== (c = /*$justification*/
|
1111
|
-
b[25].length === 0) && (t.disabled = c), r[0] & /*$_*/
|
1112
|
-
1048576 && n !== (n = /*$_*/
|
1113
|
-
b[20]("faceCollector.retakePhoto") + "") && W(f, n);
|
1114
|
-
},
|
1115
|
-
d(b) {
|
1116
|
-
b && w(e), g = !1, bt(E);
|
1117
|
-
}
|
1118
|
-
};
|
1119
|
-
}
|
1120
|
-
function Vi(l) {
|
1121
|
-
let e, t = (
|
1122
|
-
/*$_*/
|
1123
|
-
l[20]("faceCollector.everythingOk") + ""
|
1124
|
-
), s;
|
1125
|
-
return {
|
1126
|
-
c() {
|
1127
|
-
e = h("h1"), s = T(t), o(e, "class", "text-3xl font-bold pb-[1em] transition-opacity");
|
1128
|
-
},
|
1129
|
-
m(a, c) {
|
1130
|
-
p(a, e, c), u(e, s);
|
1131
|
-
},
|
1132
|
-
p(a, c) {
|
1133
|
-
c[0] & /*$_*/
|
1134
|
-
1048576 && t !== (t = /*$_*/
|
1135
|
-
a[20]("faceCollector.everythingOk") + "") && W(s, t);
|
1136
|
-
},
|
1137
|
-
d(a) {
|
1138
|
-
a && w(e);
|
1139
|
-
}
|
1140
|
-
};
|
1141
|
-
}
|
1142
|
-
function Ki(l) {
|
1143
|
-
let e, t = (
|
1144
|
-
/*$_*/
|
1145
|
-
l[20]("faceCollector.unableToCompleteRequest") + ""
|
1146
|
-
), s;
|
1147
|
-
return {
|
1148
|
-
c() {
|
1149
|
-
e = h("h1"), s = T(t), o(e, "class", "text-3xl font-bold pb-[1em] transition-opacity text-error");
|
1150
|
-
},
|
1151
|
-
m(a, c) {
|
1152
|
-
p(a, e, c), u(e, s);
|
1153
|
-
},
|
1154
|
-
p(a, c) {
|
1155
|
-
c[0] & /*$_*/
|
1156
|
-
1048576 && t !== (t = /*$_*/
|
1157
|
-
a[20]("faceCollector.unableToCompleteRequest") + "") && W(s, t);
|
1158
|
-
},
|
1159
|
-
d(a) {
|
1160
|
-
a && w(e);
|
1161
|
-
}
|
1162
|
-
};
|
1163
|
-
}
|
1164
|
-
function ji(l) {
|
1165
|
-
let e, t = (
|
1166
|
-
/*$_*/
|
1167
|
-
l[20]("faceCollector.lowQualityCapture") + ""
|
1168
|
-
), s;
|
1169
|
-
return {
|
1170
|
-
c() {
|
1171
|
-
e = h("h1"), s = T(t), o(e, "class", "text-3xl font-bold pb-[1em] transition-opacity text-error");
|
1172
|
-
},
|
1173
|
-
m(a, c) {
|
1174
|
-
p(a, e, c), u(e, s);
|
1175
|
-
},
|
1176
|
-
p(a, c) {
|
1177
|
-
c[0] & /*$_*/
|
1178
|
-
1048576 && t !== (t = /*$_*/
|
1179
|
-
a[20]("faceCollector.lowQualityCapture") + "") && W(s, t);
|
1180
|
-
},
|
1181
|
-
d(a) {
|
1182
|
-
a && w(e);
|
1183
|
-
}
|
1184
|
-
};
|
1185
|
-
}
|
1186
|
-
function qi(l) {
|
1187
|
-
let e, t = (
|
1188
|
-
/*$_*/
|
1189
|
-
l[20]("liveness.error.error") + ""
|
1190
|
-
), s, a, c = (
|
1191
|
-
/*$_*/
|
1192
|
-
l[20]("faceCollector.unaliveCapture") + ""
|
1193
|
-
), d;
|
1194
|
-
return {
|
1195
|
-
c() {
|
1196
|
-
e = h("h1"), s = T(t), a = T(": "), d = T(c), o(e, "class", "text-3xl font-bold pb-[1em] transition-opacity text-error");
|
1197
|
-
},
|
1198
|
-
m(m, n) {
|
1199
|
-
p(m, e, n), u(e, s), u(e, a), u(e, d);
|
1200
|
-
},
|
1201
|
-
p(m, n) {
|
1202
|
-
n[0] & /*$_*/
|
1203
|
-
1048576 && t !== (t = /*$_*/
|
1204
|
-
m[20]("liveness.error.error") + "") && W(s, t), n[0] & /*$_*/
|
1205
|
-
1048576 && c !== (c = /*$_*/
|
1206
|
-
m[20]("faceCollector.unaliveCapture") + "") && W(d, c);
|
1207
|
-
},
|
1208
|
-
d(m) {
|
1209
|
-
m && w(e);
|
1210
|
-
}
|
1211
|
-
};
|
1212
|
-
}
|
1213
|
-
function zi(l) {
|
1214
|
-
let e, t = (
|
1215
|
-
/*$_*/
|
1216
|
-
l[20]("liveness.error.error") + ""
|
1217
|
-
), s, a, c = (
|
1218
|
-
/*$_*/
|
1219
|
-
l[20](
|
1220
|
-
/*livenessError*/
|
1221
|
-
l[17]
|
1222
|
-
) + ""
|
1223
|
-
), d, m;
|
1224
|
-
return {
|
1225
|
-
c() {
|
1226
|
-
e = h("h1"), s = T(t), a = T(": "), d = T(c), m = T("."), o(e, "class", "text-3xl font-bold pb-[1em] transition-opacity text-error");
|
1227
|
-
},
|
1228
|
-
m(n, f) {
|
1229
|
-
p(n, e, f), u(e, s), u(e, a), u(e, d), u(e, m);
|
1230
|
-
},
|
1231
|
-
p(n, f) {
|
1232
|
-
f[0] & /*$_*/
|
1233
|
-
1048576 && t !== (t = /*$_*/
|
1234
|
-
n[20]("liveness.error.error") + "") && W(s, t), f[0] & /*$_, livenessError*/
|
1235
|
-
1179648 && c !== (c = /*$_*/
|
1236
|
-
n[20](
|
1237
|
-
/*livenessError*/
|
1238
|
-
n[17]
|
1239
|
-
) + "") && W(d, c);
|
1240
|
-
},
|
1241
|
-
d(n) {
|
1242
|
-
n && w(e);
|
1243
|
-
}
|
1244
|
-
};
|
1245
|
-
}
|
1246
|
-
function Zi(l) {
|
1247
|
-
let e, t, s, a, c = q(), d, m = (
|
1248
|
-
/*unique*/
|
1249
|
-
l[10]
|
1250
|
-
), n, f, g, E, b, r, _, y, O, R, C = (
|
1251
|
-
/*$_*/
|
1252
|
-
l[20]("faceCollector.capturing") + ""
|
1253
|
-
), U, _e, ce, Q, ae, j, Oe, ue, M, V, D, te, x, be, et, Be, He, tt, I = q() && /*waitingIdrndCaptureEvent*/
|
1254
|
-
l[16], le, Ie = q() && /*idrndLoading*/
|
1255
|
-
l[14] && /*$cameraStatusStore*/
|
1256
|
-
l[30] === re.OK, Y, z, fe, we, H, $, he, ke = c && pi(l), pe = Qt(l);
|
1257
|
-
f = new Bl({ props: { className: "bottom-0" } });
|
1258
|
-
function je(v, F) {
|
1259
|
-
return !/*$faceValidationsStore*/
|
1260
|
-
v[32].isPersonCloseEnough || /*$faceValidationsStore*/
|
1261
|
-
v[32].isPersonTooclose ? vi : gi;
|
1262
|
-
}
|
1263
|
-
let Ae = je(l), de = Ae(l);
|
1264
|
-
function Se(v, F) {
|
1265
|
-
return (
|
1266
|
-
/*$faceValidationsStore*/
|
1267
|
-
v[32].closedMouth ? ki : wi
|
1268
|
-
);
|
1269
|
-
}
|
1270
|
-
let X = Se(l), ie = X(l);
|
1271
|
-
function K(v, F) {
|
1272
|
-
return (
|
1273
|
-
/*$isLoading*/
|
1274
|
-
v[33] ? Ei : Ci
|
1275
|
-
);
|
1276
|
-
}
|
1277
|
-
let ge = K(l), oe = ge(l);
|
1278
|
-
function Ue(v, F) {
|
1279
|
-
return (
|
1280
|
-
/*$faceValidationsStore*/
|
1281
|
-
v[32].isPersonInFrame ? Li : Ri
|
1282
|
-
);
|
1283
|
-
}
|
1284
|
-
let Ce = Ue(l), me = Ce(l), ee = I && Xt(l), B = Ie && Jt(l);
|
1285
|
-
function qe(v, F) {
|
1286
|
-
return (
|
1287
|
-
/*$captured*/
|
1288
|
-
v[18] ? Ai : Si
|
1289
|
-
);
|
1290
|
-
}
|
1291
|
-
let Te = qe(l), ne = Te(l);
|
1292
|
-
const ze = [Mi, xi], Le = [];
|
1293
|
-
function Pe(v, F) {
|
1294
|
-
return !/*idrndClosed*/
|
1295
|
-
v[15] || /*$captured*/
|
1296
|
-
v[18] ? 0 : (
|
1297
|
-
/*$cameraStatusStore*/
|
1298
|
-
v[30] !== re.OK ? 1 : -1
|
1299
|
-
);
|
1300
|
-
}
|
1301
|
-
return ~(H = Pe(l)) && ($ = Le[H] = ze[H](l)), {
|
1302
|
-
c() {
|
1303
|
-
e = h("div"), t = h("div"), s = h("div"), a = h("div"), ke && ke.c(), d = L(), pe.c(), n = L(), It(f.$$.fragment), g = L(), E = h("canvas"), b = L(), r = h("canvas"), _ = L(), y = h("canvas"), O = L(), R = h("span"), U = T(C), ce = L(), Q = h("div"), ae = h("div"), j = h("span"), j.textContent = "Longe", Oe = L(), de.c(), ue = L(), M = h("div"), V = h("span"), V.textContent = "Boca Aberta", D = L(), ie.c(), te = L(), x = h("div"), be = h("span"), oe.c(), et = L(), me.c(), tt = L(), ee && ee.c(), le = L(), B && B.c(), Y = L(), z = h("div"), ne.c(), we = L(), $ && $.c(), this.c = G, o(E, "id", "bry-ce-displayCanvas"), o(E, "class", "max-w-full -scale-x-100"), o(r, "id", "bry-ce-detectionsCanvas"), o(r, "class", "absolute top-0 left-0 max-w-full -scale-x-100"), o(y, "id", "bry-ce-maskCanvas"), o(y, "class", "absolute top-0 left-0 max-w-full"), R.hidden = _e = !/*isCountingDown*/
|
1304
|
-
l[9], o(R, "class", "absolute left-1/2 -translate-x-1/2 top-[85%] text-[1.5rem] bg-info text-info-content p-1 rounded-md"), o(ae, "class", "ce-dui-badge ce-dui-badge-lg h-[2em] text-2xs sm:text-base w-[10.1em]"), o(M, "class", "ce-dui-badge ce-dui-badge-lg h-[2em] text-[.1em] 2xs:text-2xs sm:text-base w-[9.6em]"), o(x, "class", "ce-dui-badge ce-dui-badge-lg h-[2em] text-2xs sm:text-base w-[10em]"), o(Q, "class", Be = "absolute " + /*$enableFaceApi*/
|
1305
|
-
(l[28] ? "flex" : "hidden") + " justify-around w-full top-[5%]"), o(a, "class", "relative"), a.hidden = He = q() && /*idrndLoading*/
|
1306
|
-
(l[14] || /*idrndClosed*/
|
1307
|
-
l[15] || /*waitingIdrndCaptureEvent*/
|
1308
|
-
l[16]), o(z, "class", "px-4 sm:px-0 mt-[1em]"), z.hidden = fe = q() && /*idrndLoading*/
|
1309
|
-
(l[14] || /*idrndClosed*/
|
1310
|
-
l[15] || /*waitingIdrndCaptureEvent*/
|
1311
|
-
l[16]), o(s, "class", "relative mx-auto"), o(t, "class", "flex flex-col justify-between");
|
1312
|
-
},
|
1313
|
-
m(v, F) {
|
1314
|
-
p(v, e, F), u(e, t), u(t, s), u(s, a), ke && ke.m(a, null), u(a, d), pe.m(a, null), u(a, n), At(f, a, null), u(a, g), u(a, E), l[49](E), u(a, b), u(a, r), l[50](r), u(a, _), u(a, y), l[51](y), u(a, O), u(a, R), u(R, U), l[52](R), u(a, ce), u(a, Q), u(Q, ae), u(ae, j), u(ae, Oe), de.m(ae, null), l[53](ae), u(Q, ue), u(Q, M), u(M, V), u(M, D), ie.m(M, null), l[54](M), u(Q, te), u(Q, x), u(x, be), oe.m(be, null), u(x, et), me.m(x, null), l[55](x), u(s, tt), ee && ee.m(s, null), u(s, le), B && B.m(s, null), u(s, Y), u(s, z), ne.m(z, null), l[59](t), u(e, we), ~H && Le[H].m(e, null), he = !0;
|
1315
|
-
},
|
1316
|
-
p(v, F) {
|
1317
|
-
c && ke.p(v, F), F[0] & /*unique*/
|
1318
|
-
1024 && Ot(m, m = /*unique*/
|
1319
|
-
v[10]) ? (pe.d(1), pe = Qt(v), pe.c(), pe.m(a, n)) : pe.p(v, F), (!he || F[0] & /*$_*/
|
1320
|
-
1048576) && C !== (C = /*$_*/
|
1321
|
-
v[20]("faceCollector.capturing") + "") && W(U, C), (!he || F[0] & /*isCountingDown*/
|
1322
|
-
512 && _e !== (_e = !/*isCountingDown*/
|
1323
|
-
v[9])) && (R.hidden = _e), Ae !== (Ae = je(v)) && (de.d(1), de = Ae(v), de && (de.c(), de.m(ae, null))), X !== (X = Se(v)) && (ie.d(1), ie = X(v), ie && (ie.c(), ie.m(M, null))), ge === (ge = K(v)) && oe ? oe.p(v, F) : (oe.d(1), oe = ge(v), oe && (oe.c(), oe.m(be, null))), Ce !== (Ce = Ue(v)) && (me.d(1), me = Ce(v), me && (me.c(), me.m(x, null))), (!he || F[0] & /*$enableFaceApi*/
|
1324
|
-
268435456 && Be !== (Be = "absolute " + /*$enableFaceApi*/
|
1325
|
-
(v[28] ? "flex" : "hidden") + " justify-around w-full top-[5%]")) && o(Q, "class", Be), (!he || F[0] & /*idrndLoading, idrndClosed, waitingIdrndCaptureEvent*/
|
1326
|
-
114688 && He !== (He = q() && /*idrndLoading*/
|
1327
|
-
(v[14] || /*idrndClosed*/
|
1328
|
-
v[15] || /*waitingIdrndCaptureEvent*/
|
1329
|
-
v[16]))) && (a.hidden = He), F[0] & /*waitingIdrndCaptureEvent*/
|
1330
|
-
65536 && (I = q() && /*waitingIdrndCaptureEvent*/
|
1331
|
-
v[16]), I ? ee ? ee.p(v, F) : (ee = Xt(v), ee.c(), ee.m(s, le)) : ee && (ee.d(1), ee = null), F[0] & /*idrndLoading, $cameraStatusStore*/
|
1332
|
-
1073758208 && (Ie = q() && /*idrndLoading*/
|
1333
|
-
v[14] && /*$cameraStatusStore*/
|
1334
|
-
v[30] === re.OK), Ie ? B ? B.p(v, F) : (B = Jt(v), B.c(), B.m(s, Y)) : B && (B.d(1), B = null), Te === (Te = qe(v)) && ne ? ne.p(v, F) : (ne.d(1), ne = Te(v), ne && (ne.c(), ne.m(z, null))), (!he || F[0] & /*idrndLoading, idrndClosed, waitingIdrndCaptureEvent*/
|
1335
|
-
114688 && fe !== (fe = q() && /*idrndLoading*/
|
1336
|
-
(v[14] || /*idrndClosed*/
|
1337
|
-
v[15] || /*waitingIdrndCaptureEvent*/
|
1338
|
-
v[16]))) && (z.hidden = fe);
|
1339
|
-
let De = H;
|
1340
|
-
H = Pe(v), H === De ? ~H && Le[H].p(v, F) : ($ && (sl(), Ne(Le[De], 1, 1, () => {
|
1341
|
-
Le[De] = null;
|
1342
|
-
}), al()), ~H ? ($ = Le[H], $ ? $.p(v, F) : ($ = Le[H] = ze[H](v), $.c()), Fe($, 1), $.m(e, null)) : $ = null);
|
1343
|
-
},
|
1344
|
-
i(v) {
|
1345
|
-
he || (Fe(f.$$.fragment, v), Fe($), he = !0);
|
1346
|
-
},
|
1347
|
-
o(v) {
|
1348
|
-
Ne(f.$$.fragment, v), Ne($), he = !1;
|
1349
|
-
},
|
1350
|
-
d(v) {
|
1351
|
-
v && w(e), ke && ke.d(), pe.d(v), St(f), l[49](null), l[50](null), l[51](null), l[52](null), de.d(), l[53](null), ie.d(), l[54](null), oe.d(), me.d(), l[55](null), ee && ee.d(), B && B.d(), ne.d(), l[59](null), ~H && Le[H].d();
|
1352
|
-
}
|
1353
|
-
};
|
1354
|
-
}
|
1355
|
-
function el(l, e, t) {
|
1356
|
-
const s = e.videoHeight >= e.videoWidth && t.height >= t.width || e.videoHeight < e.videoWidth && t.height < t.width;
|
1357
|
-
l.drawImage(
|
1358
|
-
e,
|
1359
|
-
s ? 0 : e.videoWidth / 2 - t.width,
|
1360
|
-
0,
|
1361
|
-
s ? e.videoWidth : e.videoHeight * (t.width / t.height),
|
1362
|
-
e.videoHeight,
|
1363
|
-
0,
|
1364
|
-
0,
|
1365
|
-
t.width,
|
1366
|
-
t.height
|
1367
|
-
);
|
1368
|
-
}
|
1369
|
-
function Qi(l, e, t) {
|
1370
|
-
let s, a, c, d, m, n, f, g, E, b, r, _, y, O, R, C, U, _e, ce, Q, ae, j, Oe, ue, M, V, D, te, x, be, et, Be, He, tt;
|
1371
|
-
S(l, gt, (i) => t(73, s = i)), S(l, lt, (i) => t(18, c = i)), S(l, vt, (i) => t(75, d = i)), S(l, Ft, (i) => t(76, m = i)), S(l, Je, (i) => t(19, n = i)), S(l, Hl, (i) => t(77, f = i)), S(l, Ul, (i) => t(20, g = i)), S(l, Vl, (i) => t(78, E = i)), S(l, Re, (i) => t(21, b = i)), S(l, Kl, (i) => t(22, r = i)), S(l, Ge, (i) => t(23, _ = i)), S(l, it, (i) => t(79, y = i)), S(l, wt, (i) => t(24, O = i)), S(l, kt, (i) => t(25, R = i)), S(l, xe, (i) => t(26, C = i)), S(l, jl, (i) => t(80, _e = i)), S(l, ql, (i) => t(28, ce = i)), S(l, ot, (i) => t(29, Q = i)), S(l, Ct, (i) => t(81, ae = i)), S(l, Ke, (i) => t(30, j = i)), S(l, zl, (i) => t(82, Oe = i)), S(l, nt, (i) => t(83, ue = i)), S(l, Wt, (i) => t(84, M = i)), S(l, Bt, (i) => t(85, V = i)), S(l, Ht, (i) => t(86, D = i)), S(l, Zl, (i) => t(87, te = i)), S(l, Et, (i) => t(88, x = i)), S(l, Ut, (i) => t(31, be = i)), S(l, Vt, (i) => t(32, et = i)), S(l, Ql, (i) => t(33, Be = i)), S(l, Xl, (i) => t(34, He = i)), S(l, Jl, (i) => t(35, tt = i));
|
1372
|
-
let I, le, Ie, Y, z, fe, we, H = !1, $ = {}, he = !1, { enableMinutiae: ke } = e, { videoDimensions: pe } = e, { noTabs: je } = e, { weightsPath: Ae } = e;
|
1373
|
-
const de = yt(!1);
|
1374
|
-
S(l, de, (i) => t(74, a = i));
|
1375
|
-
const Se = yt("data:image/png;base64");
|
1376
|
-
S(l, Se, (i) => t(27, U = i));
|
1377
|
-
let { widgetInstance: X } = e, ie, K, ge = !1, oe = !1, Ue = !0, Ce = !1, me = !1, ee = 0, B = "", qe = 0, Te = !1;
|
1378
|
-
const ne = Gl.mixin({
|
1379
|
-
toast: !0,
|
1380
|
-
position: "bottom-left",
|
1381
|
-
timer: 13e3,
|
1382
|
-
timerProgressBar: !0
|
1383
|
-
});
|
1384
|
-
Yl(async () => {
|
1385
|
-
k(ot, Q = !1, Q), k(Ut, be = !1, be);
|
1386
|
-
const [i, P] = (pe ?? "")?.replaceAll(" ", "")?.split("x")?.map((A) => A ? parseInt(A) : void 0);
|
1387
|
-
if (!(!i || !P)) {
|
1388
|
-
if (P > i && !q() && Kt() ? k(Je, n = { videoWidth: P, videoHeight: i }, n) : q() && P < i && Kt() ? k(Je, n = { videoWidth: P, videoHeight: i }, n) : k(Je, n = { videoWidth: i, videoHeight: P }, n), !q())
|
1389
|
-
try {
|
1390
|
-
await jt(), (await navigator.mediaDevices.getUserMedia({
|
1391
|
-
video: {
|
1392
|
-
height: { exact: P },
|
1393
|
-
width: { exact: i }
|
1394
|
-
},
|
1395
|
-
audio: !1
|
1396
|
-
}))?.getTracks()?.forEach((N) => N?.stop()), k(Et, x = te[0].deviceId, x);
|
1397
|
-
} catch (A) {
|
1398
|
-
const N = A;
|
1399
|
-
console.error(N), $l(N) && "message" in N && N.message.includes("Permission denied") && (console.error("User didn't give permission to use camera!"), k(Ht, D = !0, D));
|
1400
|
-
}
|
1401
|
-
q() && (import("./index-no-detector_c7c1d3a2_2.0.4.js"), Le()), ce && (await ei(Ae), he = !0), q() && !oe && M && Pe();
|
1402
|
-
}
|
1403
|
-
});
|
1404
|
-
function ze(i, P) {
|
1405
|
-
i.clearRect(0, 0, K.width, K.height), i.save(), i.filter = "blur(7px)", i.beginPath(), i.rect(0, 0, K.width, K.height);
|
1406
|
-
let A = 200;
|
1407
|
-
n.videoWidth > n.videoHeight ? A = 1.1 * (100 * n.videoWidth) / n.videoHeight * 1.1 : A = 1.1 * (100 * n.videoHeight * 1.1) / n.videoWidth;
|
1408
|
-
const N = A * 1.45;
|
1409
|
-
i.ellipse(n.videoWidth / 2, n.videoHeight / 2, A / 2, N / 2, 0, 0, 2 * Math.PI, !0), i.clip(), el(i, P, K), i.restore(), i.save(), i.beginPath();
|
1410
|
-
const ve = window.getComputedStyle(K).getPropertyValue("--p"), Qe = window.getComputedStyle(K).getPropertyValue("--su");
|
1411
|
-
if (i.strokeStyle = `hsl(${ve})`, i.lineWidth = 16, i.ellipse(n.videoWidth / 2, n.videoHeight / 2, A / 2, N / 2, 0, 0, 2 * Math.PI), i.stroke(), H && !Te) {
|
1412
|
-
const st = 1 - (qe - (/* @__PURE__ */ new Date()).getTime()) / 4500;
|
1413
|
-
i.save(), i.beginPath(), i.lineWidth = 16, i.strokeStyle = `hsl(${Qe})`, i.ellipse(n.videoWidth / 2, n.videoHeight / 2, A / 2, N / 2, 0, 0 - Math.PI / 2, 1.25 * (Math.PI * 2 * st) - Math.PI / 2), i.stroke();
|
1414
|
-
}
|
1415
|
-
i.beginPath();
|
1416
|
-
const Xe = new Path2D();
|
1417
|
-
Xe.ellipse(n.videoWidth / 2, n.videoHeight / 2, A / 2, N / 2, 0, 0, 2 * Math.PI), i.clip(Xe), el(i, P, K), i.restore();
|
1418
|
-
}
|
1419
|
-
function Le() {
|
1420
|
-
X.addEventListener("open", (i) => {
|
1421
|
-
const P = i.detail[0].video;
|
1422
|
-
k(
|
1423
|
-
Bt,
|
1424
|
-
V = {
|
1425
|
-
width: P.videoWidth,
|
1426
|
-
height: P.videoHeight
|
1427
|
-
},
|
1428
|
-
V
|
1429
|
-
), t(2, I.srcObject = P.srcObject, I), t(14, Ue = !1);
|
1430
|
-
function A() {
|
1431
|
-
Ce || (ze(K.getContext("2d"), P), Ye(I, A, !0));
|
1432
|
-
}
|
1433
|
-
A();
|
1434
|
-
}), X.addEventListener("error", (i) => {
|
1435
|
-
console.error(i), i.detail[0].message === "Device in use" ? k(Ke, j = re.CAMERA_IN_USE_ERROR, j) : i.detail[0].message === "Permission denied" || i.detail[0].message === "Permission dismissed" ? k(Ke, j = re.CAMERA_DENIED_ERROR, j) : i.detail[0].message === "Requested device not found" && k(Ke, j = re.DEVICE_NOT_FOUND_ERROR, j), t(14, Ue = !1);
|
1436
|
-
}), X.addEventListener("faceDetection", (i) => {
|
1437
|
-
}), X.addEventListener("close", async (i) => {
|
1438
|
-
c || t(13, ge = !1), t(15, Ce = !0), t(16, me = !1), j === re.OK && k(Ke, j = re.CAMERA_CLOSED_ERROR, j);
|
1439
|
-
}), X.addEventListener("initialize", async (i) => {
|
1440
|
-
oe = !0, k(Wt, M = !0, M), ae === rt.Face && !ge && !c && oe && await Pe();
|
1441
|
-
}), X.addEventListener("capture", async (i) => {
|
1442
|
-
t(17, B = "");
|
1443
|
-
const { encryptedFile: P, photo: A } = i.detail[0];
|
1444
|
-
k(nt, ue = P, ue), t(16, me = !1), k(Re, b = J.OK, b), k(Ge, _.isLoading = !0, _), k(lt, c = !0, c), t(13, ge = !1);
|
1445
|
-
const N = (await ct(A)).split(",");
|
1446
|
-
if (k(Se, U = N[0], U), k(xe, C = N[1], C), k(it, y = N[1], y), !Oe) {
|
1447
|
-
let Ee, ht;
|
1448
|
-
try {
|
1449
|
-
({ bodyParts: Ee, icaoWarnings: ht } = await ut(y, (await ct(P)).split(",")[1])), window.dispatchEvent(new CustomEvent(
|
1450
|
-
"face-unconformities-validated",
|
1451
|
-
{
|
1452
|
-
detail: {
|
1453
|
-
bodyParts: Ee,
|
1454
|
-
icaoWarnings: ht,
|
1455
|
-
status: b
|
1456
|
-
}
|
1457
|
-
}
|
1458
|
-
));
|
1459
|
-
} catch (Ve) {
|
1460
|
-
console.error(Ve);
|
1461
|
-
let at = Rt.UNKNOWN, pt = [], xt = [];
|
1462
|
-
if (Ve instanceof qt && Ve.response?.status === 400)
|
1463
|
-
if (Ve.response.data && Array.isArray(Ve.response.data.bodyParts)) {
|
1464
|
-
pt = Ve.response.data.bodyParts, xt = Ve.response.data.icaoWarnings;
|
1465
|
-
const Mt = pt.find((Wl) => Wl.livenessResult.error);
|
1466
|
-
at = Mt?.livenessResult.error_code, k(Re, b = J.LIVENESS_DETECTION_FAILURE, b), Mt?.livenessResult.error_code || k(Re, b = J.UNKNOWN_LIVENESS_ERROR, b), t(17, B = Rt[at]), console.error("Liveness error:", at);
|
1467
|
-
} else
|
1468
|
-
k(Re, b = J.TEMPLATE_EXTRACTION_ERROR, b);
|
1469
|
-
else
|
1470
|
-
k(Re, b = J.UNKNOWN_LIVENESS_ERROR, b), ne.fire({
|
1471
|
-
icon: "error",
|
1472
|
-
title: "Falha ao comunicar com serviço de Liveness"
|
1473
|
-
});
|
1474
|
-
k(Ge, _.isLoading = !1, _), window.dispatchEvent(new CustomEvent(
|
1475
|
-
"face-unconformities-validated",
|
1476
|
-
{
|
1477
|
-
detail: {
|
1478
|
-
bodyParts: pt,
|
1479
|
-
errorCode: at,
|
1480
|
-
translatedError: g(B),
|
1481
|
-
status: b,
|
1482
|
-
icaoWarnings: xt
|
1483
|
-
}
|
1484
|
-
}
|
1485
|
-
));
|
1486
|
-
return;
|
1487
|
-
}
|
1488
|
-
if (b !== J.OK) {
|
1489
|
-
k(Ge, _.isLoading = !1, _);
|
1490
|
-
return;
|
1491
|
-
}
|
1492
|
-
Tt(Ee[0].livenessResult), Ee.length !== 0 && Ee[0].data && k(xe, C = Ee[0].data, C), ft(ht);
|
1493
|
-
return;
|
1494
|
-
}
|
1495
|
-
let ve, Qe;
|
1496
|
-
try {
|
1497
|
-
Qe = await ti(P), Tt(Qe.data);
|
1498
|
-
} catch (Ee) {
|
1499
|
-
k(Re, b = J.UNKNOWN_LIVENESS_ERROR, b), console.error(Ee), Ee instanceof qt && Ee.response?.status === 400 ? (ve = Ee.response.data.error_code, t(17, B = Rt[ve]), console.error("Liveness error:", ve), k(Re, b = J.LIVENESS_DETECTION_FAILURE, b)) : ne.fire({
|
1500
|
-
icon: "error",
|
1501
|
-
title: "Falha ao comunicar com serviço de Liveness"
|
1502
|
-
});
|
1503
|
-
}
|
1504
|
-
if (b !== J.OK) {
|
1505
|
-
k(Ge, _.isLoading = !1, _), window.dispatchEvent(new CustomEvent(
|
1506
|
-
"face-unconformities-validated",
|
1507
|
-
{
|
1508
|
-
detail: {
|
1509
|
-
bodyParts: [
|
1510
|
-
{
|
1511
|
-
bodyPart: "FACE",
|
1512
|
-
data: y,
|
1513
|
-
livenessBlob: (await ct(P)).split(",")[1],
|
1514
|
-
...Qe && { livenessResult: Qe }
|
1515
|
-
}
|
1516
|
-
],
|
1517
|
-
...ve && { errorCode: ve },
|
1518
|
-
...B && { translatedError: g(B) },
|
1519
|
-
status: b
|
1520
|
-
}
|
1521
|
-
}
|
1522
|
-
));
|
1523
|
-
return;
|
1524
|
-
}
|
1525
|
-
let { bodyParts: Xe, icaoWarnings: st } = await ut(y);
|
1526
|
-
window.dispatchEvent(new CustomEvent(
|
1527
|
-
"face-unconformities-validated",
|
1528
|
-
{
|
1529
|
-
detail: {
|
1530
|
-
bodyParts: Xe,
|
1531
|
-
icaoWarnings: st,
|
1532
|
-
status: b,
|
1533
|
-
errorCode: ve,
|
1534
|
-
...B && { translatedError: g(B) }
|
1535
|
-
}
|
1536
|
-
}
|
1537
|
-
)), Xe[0].data && k(xe, C = Xe[0].data, C), ft(st);
|
1538
|
-
});
|
1539
|
-
}
|
1540
|
-
function Pe() {
|
1541
|
-
k(Ke, j = re.OK, j), X && "openCamera" in X && X.openCamera(), t(13, ge = !0), t(15, Ce = !1), t(14, Ue = !0);
|
1542
|
-
}
|
1543
|
-
async function v() {
|
1544
|
-
if (ce && !he)
|
1545
|
-
return Ye(I, v);
|
1546
|
-
if (I) {
|
1547
|
-
if (ae !== rt.Face && !je)
|
1548
|
-
return Ye(I, v);
|
1549
|
-
k(ot, Q = !0, Q), ce ? (a || k(de, a = !0, a), q() || ze(K.getContext("2d"), I), Ye(I, v)) : (ze(K.getContext("2d"), I), Ye(I, v));
|
1550
|
-
}
|
1551
|
-
}
|
1552
|
-
async function F() {
|
1553
|
-
if (k(Re, b = J.OK, b), q()) {
|
1554
|
-
t(16, me = !0), X.takePhoto();
|
1555
|
-
return;
|
1556
|
-
}
|
1557
|
-
if (k(lt, c = !0, c), ce) {
|
1558
|
-
const [i] = await (await import("./face_api_ebd7fa48_2.0.4.js")).extractFaces(I, [_e]), P = i.toDataURL("image/jpeg").split(",");
|
1559
|
-
k(Se, U = P[0], U), k(xe, C = P[1], C), k(it, y = P[1], y);
|
1560
|
-
let { bodyParts: A, icaoWarnings: N } = await ut(C);
|
1561
|
-
window.dispatchEvent(new CustomEvent(
|
1562
|
-
"face-unconformities-validated",
|
1563
|
-
{
|
1564
|
-
detail: {
|
1565
|
-
bodyParts: [{ bodyPart: "FACE", data: y }],
|
1566
|
-
icaoWarnings: N,
|
1567
|
-
status: b
|
1568
|
-
}
|
1569
|
-
}
|
1570
|
-
)), A.length !== 0 && A[0].data && k(xe, C = A[0].data, C), ft(N);
|
1571
|
-
} else {
|
1572
|
-
const i = document.createElement("canvas"), P = i.getContext("2d");
|
1573
|
-
i.width = I.width, i.height = I.height, P?.drawImage(I, 0, 0, i.width, i.height);
|
1574
|
-
const A = i.toDataURL("image/jpeg").split(",");
|
1575
|
-
k(Se, U = A[0], U), k(xe, C = A[1], C), k(it, y = A[1], y);
|
1576
|
-
let { bodyParts: N, icaoWarnings: ve } = await ut(C);
|
1577
|
-
window.dispatchEvent(new CustomEvent(
|
1578
|
-
"face-unconformities-validated",
|
1579
|
-
{
|
1580
|
-
detail: {
|
1581
|
-
bodyParts: [{ bodyPart: "FACE", data: y }],
|
1582
|
-
icaoWarnings: ve,
|
1583
|
-
status: b
|
1584
|
-
}
|
1585
|
-
}
|
1586
|
-
)), N.length !== 0 && N[0].data && k(xe, C = N[0].data, C), ft(ve);
|
1587
|
-
}
|
1588
|
-
}
|
1589
|
-
function De() {
|
1590
|
-
const i = {
|
1591
|
-
bodyPart: "FACE",
|
1592
|
-
data: y || C,
|
1593
|
-
justification: R
|
1594
|
-
};
|
1595
|
-
k(wt, O = !0, O), Pt(nt) && ct(Pt(nt)).then((P) => {
|
1596
|
-
i.livenessBlob = P.split(",")[1];
|
1597
|
-
}), window.dispatchEvent(new CustomEvent("export-face", { detail: i }));
|
1598
|
-
}
|
1599
|
-
function Ze() {
|
1600
|
-
window.dispatchEvent(new CustomEvent("face-scrapped")), k(wt, O = !1, O), k(Re, b = J.OK, b), k(lt, c = !1, c), k(it, y = "", y), k(Ge, _.unconformities = [], _), Ce && Pe();
|
1601
|
-
}
|
1602
|
-
function Tt(i) {
|
1603
|
-
let P = "", A = "success";
|
1604
|
-
i.isAlive ? P = `Vivacidade de face (${i.face_liveness.probability.toFixed(2)}) e de captura (${i.capture_liveness.probability}, ${i.capture_liveness.score.toFixed(2)}) verificados!` : i?.face_liveness?.probability && (A = "error", P = `Vivacidade de face (${i.face_liveness.probability.toFixed(2)}) e de captura (${i.capture_liveness.probability}, ${i.capture_liveness.score.toFixed(2)}) insuficientes!`, r && k(Re, b = J.LOW_LIVENESS_SCORE, b)), E && ne.fire({ icon: A, title: P });
|
1605
|
-
}
|
1606
|
-
const rl = Je.subscribe((i) => {
|
1607
|
-
I && le && (t(2, I.width = i.videoWidth, I), t(2, I.height = i.videoHeight, I), t(3, le.width = i.videoWidth, le), t(3, le.height = i.videoHeight, le), t(11, ie.width = i.videoWidth, ie), t(11, ie.height = i.videoHeight, ie), t(12, K.width = i.videoWidth, K), t(12, K.height = i.videoHeight, K));
|
1608
|
-
}), cl = Vt.subscribe((i) => {
|
1609
|
-
if (!(!Y || !z || !fe) && (i.closedMouth ? (z.classList.add("ce-dui-badge-success"), z.classList.remove("ce-dui-badge-error"), t(6, z.firstChild.textContent = g("faceCollector.closedMouth"), z)) : (z.classList.remove("ce-dui-badge-success"), z.classList.add("ce-dui-badge-error"), t(6, z.firstChild.textContent = g("faceCollector.mouthOpen"), z)), !i.isPersonCloseEnough || i.isPersonTooclose ? (Y.classList.remove("ce-dui-badge-success"), Y.classList.add("ce-dui-badge-error"), i.isPersonCloseEnough ? i.isPersonTooclose && t(5, Y.firstChild.textContent = g("faceCollector.tooClose"), Y) : t(5, Y.firstChild.textContent = g("faceCollector.tooFar"), Y)) : (Y.classList.add("ce-dui-badge-success"), Y.classList.remove("ce-dui-badge-error"), t(5, Y.firstChild.textContent = g("faceCollector.okDistance"), Y)), i.isPersonInFrame ? (fe.classList.add("ce-dui-badge-success"), fe.classList.remove("ce-dui-badge-error")) : (fe.classList.remove("ce-dui-badge-success"), fe.classList.add("ce-dui-badge-error")), !c && f && !H && Ie && i.isPersonInFrame && i.closedMouth && !(!i.isPersonCloseEnough || i.isPersonTooclose))) {
|
1610
|
-
t(9, H = !0), qe = (/* @__PURE__ */ new Date()).getTime() + 4500;
|
1611
|
-
const P = setInterval(
|
1612
|
-
() => {
|
1613
|
-
if (!f || c || q() && Ce || !i.isPersonCloseEnough || i.isPersonTooclose || !i.closedMouth || !i.isPersonInFrame) {
|
1614
|
-
t(9, H = !1), Te = !0, setTimeout(
|
1615
|
-
() => {
|
1616
|
-
Te = !1;
|
1617
|
-
},
|
1618
|
-
1500
|
1619
|
-
), clearInterval(P);
|
1620
|
-
return;
|
1621
|
-
}
|
1622
|
-
const A = (/* @__PURE__ */ new Date()).getTime();
|
1623
|
-
Math.floor((qe - A) % (1e3 * 60) / 1e3) <= 0 && (clearInterval(P), t(9, H = !1), document.getElementsByTagName("biometric-collector")?.[0]?.shadowRoot?.getElementById("bry-cc-capture-btn")?.click());
|
1624
|
-
},
|
1625
|
-
250
|
1626
|
-
);
|
1627
|
-
}
|
1628
|
-
}), ul = lt.subscribe((i) => {
|
1629
|
-
we && (i ? (we.classList.remove("flex"), we.classList.add("hidden")) : (we.classList.add("flex"), we.classList.remove("hidden")));
|
1630
|
-
}), fl = vt.subscribe((i) => {
|
1631
|
-
I && i && (console.log("setting null in video srcObject"), t(2, I.srcObject = null, I), t(2, I.src = "", I));
|
1632
|
-
});
|
1633
|
-
Ct.subscribe(async (i) => {
|
1634
|
-
i === rt.Face && await jt();
|
1635
|
-
});
|
1636
|
-
const dl = Et.subscribe(async (i) => {
|
1637
|
-
if (q() || !i)
|
1638
|
-
return;
|
1639
|
-
I || t(10, $ = {});
|
1640
|
-
const { videoHeight: P, videoWidth: A } = n, N = await li(A, P, i);
|
1641
|
-
t(2, I.srcObject = N, I), k(Ft, m = N, m), k(vt, d = !1, d);
|
1642
|
-
}), ml = Ct.subscribe(async (i) => {
|
1643
|
-
i === rt.Face && q() && !ge && !c && oe && await Pe();
|
1644
|
-
}), _l = de.subscribe(async (i) => {
|
1645
|
-
i && Dt();
|
1646
|
-
});
|
1647
|
-
async function Dt() {
|
1648
|
-
const i = await ii(), P = await import("./face_api_ebd7fa48_2.0.4.js");
|
1649
|
-
let A;
|
1650
|
-
A = P.detectSingleFace(K, i);
|
1651
|
-
const N = await A.withFaceLandmarks();
|
1652
|
-
le.getContext("2d")?.clearRect(0, 0, le.width, le.height), N && si(N, le, ke), a && Ye(I, Dt);
|
1653
|
-
}
|
1654
|
-
gt.subscribe(async (i) => {
|
1655
|
-
i && (Ze(), k(gt, s = !1, s));
|
1656
|
-
});
|
1657
|
-
const bl = ot.subscribe((i) => {
|
1658
|
-
i && window.dispatchEvent(new CustomEvent("brycc-camera-ready"));
|
1659
|
-
});
|
1660
|
-
ai(() => {
|
1661
|
-
oi(), ul(), cl(), rl(), fl(), dl(), ml(), clearInterval(ee), _l(), bl(), ee = 0;
|
1662
|
-
});
|
1663
|
-
function hl(i) {
|
1664
|
-
ye[i ? "unshift" : "push"](() => {
|
1665
|
-
X = i, t(0, X);
|
1666
|
-
});
|
1667
|
-
}
|
1668
|
-
function pl(i) {
|
1669
|
-
ye[i ? "unshift" : "push"](() => {
|
1670
|
-
I = i, t(2, I);
|
1671
|
-
});
|
1672
|
-
}
|
1673
|
-
const gl = () => {
|
1674
|
-
q() || k(
|
1675
|
-
Je,
|
1676
|
-
n = {
|
1677
|
-
videoHeight: I.videoHeight,
|
1678
|
-
videoWidth: I.videoWidth
|
1679
|
-
},
|
1680
|
-
n
|
1681
|
-
);
|
1682
|
-
};
|
1683
|
-
function vl(i) {
|
1684
|
-
ye[i ? "unshift" : "push"](() => {
|
1685
|
-
K = i, t(12, K);
|
1686
|
-
});
|
1687
|
-
}
|
1688
|
-
function wl(i) {
|
1689
|
-
ye[i ? "unshift" : "push"](() => {
|
1690
|
-
le = i, t(3, le);
|
1691
|
-
});
|
1692
|
-
}
|
1693
|
-
function kl(i) {
|
1694
|
-
ye[i ? "unshift" : "push"](() => {
|
1695
|
-
ie = i, t(11, ie);
|
1696
|
-
});
|
1697
|
-
}
|
1698
|
-
function Cl(i) {
|
1699
|
-
ye[i ? "unshift" : "push"](() => {
|
1700
|
-
Ie = i, t(4, Ie);
|
1701
|
-
});
|
1702
|
-
}
|
1703
|
-
function El(i) {
|
1704
|
-
ye[i ? "unshift" : "push"](() => {
|
1705
|
-
Y = i, t(5, Y);
|
1706
|
-
});
|
1707
|
-
}
|
1708
|
-
function Rl(i) {
|
1709
|
-
ye[i ? "unshift" : "push"](() => {
|
1710
|
-
z = i, t(6, z);
|
1711
|
-
});
|
1712
|
-
}
|
1713
|
-
function Ll(i) {
|
1714
|
-
ye[i ? "unshift" : "push"](() => {
|
1715
|
-
fe = i, t(7, fe);
|
1716
|
-
});
|
1717
|
-
}
|
1718
|
-
const yl = () => F(), Pl = () => De(), Ol = () => Ze();
|
1719
|
-
function Il(i) {
|
1720
|
-
ye[i ? "unshift" : "push"](() => {
|
1721
|
-
we = i, t(8, we);
|
1722
|
-
});
|
1723
|
-
}
|
1724
|
-
const Al = () => De(), Sl = () => Ze();
|
1725
|
-
function Tl() {
|
1726
|
-
R = this.value, kt.set(R);
|
1727
|
-
}
|
1728
|
-
const Dl = () => De(), xl = () => Ze();
|
1729
|
-
function Ml() {
|
1730
|
-
R = this.value, kt.set(R);
|
1731
|
-
}
|
1732
|
-
const Nl = () => Ze(), Fl = () => {
|
1733
|
-
t(13, ge = !0), Pe();
|
1734
|
-
};
|
1735
|
-
return l.$$set = (i) => {
|
1736
|
-
"enableMinutiae" in i && t(42, ke = i.enableMinutiae), "videoDimensions" in i && t(43, pe = i.videoDimensions), "noTabs" in i && t(44, je = i.noTabs), "weightsPath" in i && t(45, Ae = i.weightsPath), "widgetInstance" in i && t(0, X = i.widgetInstance);
|
1737
|
-
}, [
|
1738
|
-
X,
|
1739
|
-
v,
|
1740
|
-
I,
|
1741
|
-
le,
|
1742
|
-
Ie,
|
1743
|
-
Y,
|
1744
|
-
z,
|
1745
|
-
fe,
|
1746
|
-
we,
|
1747
|
-
H,
|
1748
|
-
$,
|
1749
|
-
ie,
|
1750
|
-
K,
|
1751
|
-
ge,
|
1752
|
-
Ue,
|
1753
|
-
Ce,
|
1754
|
-
me,
|
1755
|
-
B,
|
1756
|
-
c,
|
1757
|
-
n,
|
1758
|
-
g,
|
1759
|
-
b,
|
1760
|
-
r,
|
1761
|
-
_,
|
1762
|
-
O,
|
1763
|
-
R,
|
1764
|
-
C,
|
1765
|
-
U,
|
1766
|
-
ce,
|
1767
|
-
Q,
|
1768
|
-
j,
|
1769
|
-
be,
|
1770
|
-
et,
|
1771
|
-
Be,
|
1772
|
-
He,
|
1773
|
-
tt,
|
1774
|
-
de,
|
1775
|
-
Se,
|
1776
|
-
Pe,
|
1777
|
-
F,
|
1778
|
-
De,
|
1779
|
-
Ze,
|
1780
|
-
ke,
|
1781
|
-
pe,
|
1782
|
-
je,
|
1783
|
-
Ae,
|
1784
|
-
hl,
|
1785
|
-
pl,
|
1786
|
-
gl,
|
1787
|
-
vl,
|
1788
|
-
wl,
|
1789
|
-
kl,
|
1790
|
-
Cl,
|
1791
|
-
El,
|
1792
|
-
Rl,
|
1793
|
-
Ll,
|
1794
|
-
yl,
|
1795
|
-
Pl,
|
1796
|
-
Ol,
|
1797
|
-
Il,
|
1798
|
-
Al,
|
1799
|
-
Sl,
|
1800
|
-
Tl,
|
1801
|
-
Dl,
|
1802
|
-
xl,
|
1803
|
-
Ml,
|
1804
|
-
Nl,
|
1805
|
-
Fl
|
1806
|
-
];
|
1807
|
-
}
|
1808
|
-
class Xi extends tl {
|
1809
|
-
constructor(e) {
|
1810
|
-
super(), ll(
|
1811
|
-
this,
|
1812
|
-
{
|
1813
|
-
target: this.shadowRoot,
|
1814
|
-
props: il(this.attributes),
|
1815
|
-
customElement: !0
|
1816
|
-
},
|
1817
|
-
Qi,
|
1818
|
-
Zi,
|
1819
|
-
Ot,
|
1820
|
-
{
|
1821
|
-
enableMinutiae: 42,
|
1822
|
-
videoDimensions: 43,
|
1823
|
-
noTabs: 44,
|
1824
|
-
weightsPath: 45,
|
1825
|
-
widgetInstance: 0,
|
1826
|
-
play: 1
|
1827
|
-
},
|
1828
|
-
null,
|
1829
|
-
[-1, -1, -1, -1]
|
1830
|
-
), e && (e.target && p(e.target, this, e.anchor), e.props && (this.$set(e.props), Me()));
|
1831
|
-
}
|
1832
|
-
static get observedAttributes() {
|
1833
|
-
return [
|
1834
|
-
"enableMinutiae",
|
1835
|
-
"videoDimensions",
|
1836
|
-
"noTabs",
|
1837
|
-
"weightsPath",
|
1838
|
-
"widgetInstance",
|
1839
|
-
"play"
|
1840
|
-
];
|
1841
|
-
}
|
1842
|
-
get enableMinutiae() {
|
1843
|
-
return this.$$.ctx[42];
|
1844
|
-
}
|
1845
|
-
set enableMinutiae(e) {
|
1846
|
-
this.$$set({ enableMinutiae: e }), Me();
|
1847
|
-
}
|
1848
|
-
get videoDimensions() {
|
1849
|
-
return this.$$.ctx[43];
|
1850
|
-
}
|
1851
|
-
set videoDimensions(e) {
|
1852
|
-
this.$$set({ videoDimensions: e }), Me();
|
1853
|
-
}
|
1854
|
-
get noTabs() {
|
1855
|
-
return this.$$.ctx[44];
|
1856
|
-
}
|
1857
|
-
set noTabs(e) {
|
1858
|
-
this.$$set({ noTabs: e }), Me();
|
1859
|
-
}
|
1860
|
-
get weightsPath() {
|
1861
|
-
return this.$$.ctx[45];
|
1862
|
-
}
|
1863
|
-
set weightsPath(e) {
|
1864
|
-
this.$$set({ weightsPath: e }), Me();
|
1865
|
-
}
|
1866
|
-
get widgetInstance() {
|
1867
|
-
return this.$$.ctx[0];
|
1868
|
-
}
|
1869
|
-
set widgetInstance(e) {
|
1870
|
-
this.$$set({ widgetInstance: e }), Me();
|
1871
|
-
}
|
1872
|
-
get play() {
|
1873
|
-
return this.$$.ctx[1];
|
1874
|
-
}
|
1875
|
-
}
|
1876
|
-
customElements.define("face-collector", Xi);
|
1877
|
-
export {
|
1878
|
-
Xi as default
|
1879
|
-
};
|