interview-widget 1.0.3 → 1.0.4

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/widget.es.js CHANGED
@@ -1,9 +1,9 @@
1
- var _e = Object.defineProperty;
2
- var Le = (t, r, i) => r in t ? _e(t, r, { enumerable: !0, configurable: !0, writable: !0, value: i }) : t[r] = i;
3
- var _ = (t, r, i) => Le(t, typeof r != "symbol" ? r + "" : r, i);
4
- import fe, { createContext as je, useRef as T, useCallback as N, useMemo as X, useContext as re, useSyncExternalStore as Ne, useState as k, useEffect as C } from "react";
5
- import { createPortal as $e } from "react-dom";
6
- var ke = { exports: {} }, se = {};
1
+ var Ue = Object.defineProperty;
2
+ var qe = (i, r, t) => r in i ? Ue(i, r, { enumerable: !0, configurable: !0, writable: !0, value: t }) : i[r] = t;
3
+ var F = (i, r, t) => qe(i, typeof r != "symbol" ? r + "" : r, t);
4
+ import he, { createContext as Ee, useRef as T, useCallback as N, useMemo as X, useContext as re, useSyncExternalStore as Te, useState as k, useEffect as C } from "react";
5
+ import { createPortal as Be } from "react-dom";
6
+ var Ce = { exports: {} }, se = {};
7
7
  /**
8
8
  * @license React
9
9
  * react-jsx-runtime.production.js
@@ -13,27 +13,27 @@ var ke = { exports: {} }, se = {};
13
13
  * This source code is licensed under the MIT license found in the
14
14
  * LICENSE file in the root directory of this source tree.
15
15
  */
16
- var Oe = Symbol.for("react.transitional.element"), qe = Symbol.for("react.fragment");
17
- function Ee(t, r, i) {
16
+ var We = Symbol.for("react.transitional.element"), Ge = Symbol.for("react.fragment");
17
+ function Se(i, r, t) {
18
18
  var s = null;
19
- if (i !== void 0 && (s = "" + i), r.key !== void 0 && (s = "" + r.key), "key" in r) {
20
- i = {};
19
+ if (t !== void 0 && (s = "" + t), r.key !== void 0 && (s = "" + r.key), "key" in r) {
20
+ t = {};
21
21
  for (var n in r)
22
- n !== "key" && (i[n] = r[n]);
23
- } else i = r;
24
- return r = i.ref, {
25
- $$typeof: Oe,
26
- type: t,
22
+ n !== "key" && (t[n] = r[n]);
23
+ } else t = r;
24
+ return r = t.ref, {
25
+ $$typeof: We,
26
+ type: i,
27
27
  key: s,
28
28
  ref: r !== void 0 ? r : null,
29
- props: i
29
+ props: t
30
30
  };
31
31
  }
32
- se.Fragment = qe;
33
- se.jsx = Ee;
34
- se.jsxs = Ee;
35
- ke.exports = se;
36
- var e = ke.exports;
32
+ se.Fragment = Ge;
33
+ se.jsx = Se;
34
+ se.jsxs = Se;
35
+ Ce.exports = se;
36
+ var e = Ce.exports;
37
37
  const $ = {
38
38
  api: {
39
39
  baseUrl: "/api",
@@ -65,56 +65,119 @@ const $ = {
65
65
  enabled: !0
66
66
  }
67
67
  }
68
- }, ne = je(null), Te = "proctoring-storage", Ue = () => {
69
- var t, r;
68
+ }, ge = "iw-storage";
69
+ function Ve() {
70
+ return typeof import.meta < "u" ? "your-secure-encryption-seed-here" : typeof process < "u" && process.env.NEXT_PUBLIC_IW_SECRET ? process.env.NEXT_PUBLIC_IW_SECRET : typeof window < "u" && window.__IW_SECRET__ ? window.__IW_SECRET__ : "proctoring-data-seed";
71
+ }
72
+ const Ie = Ve(), fe = "AES-GCM", me = 12;
73
+ async function Re(i) {
74
+ const t = new TextEncoder().encode(i), s = await crypto.subtle.digest("SHA-256", t);
75
+ return crypto.subtle.importKey("raw", s, fe, !1, [
76
+ "encrypt",
77
+ "decrypt"
78
+ ]);
79
+ }
80
+ function ze() {
81
+ return crypto.getRandomValues(new Uint8Array(me));
82
+ }
83
+ async function He(i, r = "default-seed") {
70
84
  try {
71
- const i = sessionStorage.getItem(Te);
72
- if (i) {
73
- const s = JSON.parse(i);
85
+ const t = typeof i == "string" ? i : JSON.stringify(i), n = new TextEncoder().encode(t), o = await Re(r), a = ze(), l = await crypto.subtle.encrypt(
86
+ { name: fe, iv: a },
87
+ o,
88
+ n
89
+ ), d = new Uint8Array(a.length + l.byteLength);
90
+ return d.set(new Uint8Array(a), 0), d.set(new Uint8Array(l), a.length), btoa(String.fromCharCode(...Array.from(d)));
91
+ } catch (t) {
92
+ throw console.error("Encryption failed:", t), new Error("Failed to encrypt data");
93
+ }
94
+ }
95
+ async function Ye(i, r = "default-seed") {
96
+ try {
97
+ const t = atob(i), s = new Uint8Array(t.length);
98
+ for (let c = 0; c < t.length; c++)
99
+ s[c] = t.charCodeAt(c);
100
+ const n = s.slice(0, me), o = s.slice(me), a = await Re(r), l = await crypto.subtle.decrypt(
101
+ { name: fe, iv: n },
102
+ a,
103
+ o
104
+ );
105
+ return new TextDecoder().decode(l);
106
+ } catch (t) {
107
+ throw console.error("Decryption failed:", t), new Error("Failed to decrypt data");
108
+ }
109
+ }
110
+ async function Qe(i, r = "default-seed") {
111
+ return He(i, r);
112
+ }
113
+ async function Ke(i, r = "default-seed") {
114
+ const t = await Ye(i, r);
115
+ try {
116
+ return JSON.parse(t);
117
+ } catch {
118
+ return t;
119
+ }
120
+ }
121
+ const ne = Ee(null), Je = async () => {
122
+ var i, r;
123
+ try {
124
+ const t = sessionStorage.getItem(ge);
125
+ if (t) {
126
+ const s = await Ke(t, Ie);
74
127
  return {
75
- logViolations: ((t = s.state) == null ? void 0 : t.logViolations) || [],
128
+ logViolations: ((i = s.state) == null ? void 0 : i.logViolations) || [],
76
129
  totalViolations: ((r = s.state) == null ? void 0 : r.totalViolations) || 0
77
130
  };
78
131
  }
79
- } catch (i) {
132
+ } catch (t) {
80
133
  console.error(
81
134
  "Failed to load proctoring data from session storage:",
82
- i
135
+ t
83
136
  );
84
137
  }
85
138
  return { logViolations: [], totalViolations: 0 };
86
- }, pe = (t) => {
139
+ }, ve = async (i) => {
87
140
  try {
88
- sessionStorage.setItem(
89
- Te,
90
- JSON.stringify({
91
- state: t,
141
+ const r = await Qe(
142
+ {
143
+ state: i,
92
144
  version: 0
93
- })
145
+ },
146
+ Ie
94
147
  );
148
+ sessionStorage.setItem(ge, r);
95
149
  } catch (r) {
96
150
  console.error("Failed to save proctoring data to session storage:", r);
97
151
  }
98
- }, ze = ({
99
- children: t
152
+ }, Xe = ({
153
+ children: i
100
154
  }) => {
101
- const r = T(Ue()), i = T(/* @__PURE__ */ new Set()), s = N(() => {
102
- i.current.forEach((w) => w());
103
- }, []), n = N((w) => (i.current.add(w), () => {
104
- i.current.delete(w);
155
+ const r = T({
156
+ logViolations: [],
157
+ totalViolations: 0
158
+ }), t = T(/* @__PURE__ */ new Set());
159
+ he.useEffect(() => {
160
+ Je().then((c) => {
161
+ r.current = c, s();
162
+ });
163
+ }, []);
164
+ const s = N(() => {
165
+ t.current.forEach((c) => c());
166
+ }, []), n = N((c) => (t.current.add(c), () => {
167
+ t.current.delete(c);
105
168
  }), []), o = N(() => r.current, []), a = N(
106
- (w) => {
169
+ (c) => {
107
170
  r.current = {
108
- logViolations: [...r.current.logViolations, w],
171
+ logViolations: [...r.current.logViolations, c],
109
172
  totalViolations: r.current.totalViolations + 1
110
- }, pe(r.current), s();
173
+ }, ve(r.current), s();
111
174
  },
112
175
  [s]
113
176
  ), l = N(() => {
114
177
  r.current = {
115
178
  logViolations: [],
116
179
  totalViolations: 0
117
- }, pe(r.current), s();
180
+ }, ve(r.current), s();
118
181
  }, [s]), d = X(
119
182
  () => ({
120
183
  getState: o,
@@ -124,96 +187,96 @@ const $ = {
124
187
  }),
125
188
  [o, a, l, n]
126
189
  );
127
- return /* @__PURE__ */ e.jsx(ne.Provider, { value: d, children: t });
128
- }, Be = () => {
129
- const t = re(ne);
130
- if (!t)
190
+ return /* @__PURE__ */ e.jsx(ne.Provider, { value: d, children: i });
191
+ }, Ze = () => {
192
+ const i = re(ne);
193
+ if (!i)
131
194
  throw new Error("useViolations must be used within a ProctoringProvider");
132
- return Ne(
133
- t.subscribe,
134
- () => t.getState().logViolations,
135
- () => t.getState().logViolations
195
+ return Te(
196
+ i.subscribe,
197
+ () => i.getState().logViolations,
198
+ () => i.getState().logViolations
136
199
  );
137
- }, Ge = () => {
138
- const t = re(ne);
139
- if (!t)
200
+ }, et = () => {
201
+ const i = re(ne);
202
+ if (!i)
140
203
  throw new Error(
141
204
  "useTotalViolations must be used within a ProctoringProvider"
142
205
  );
143
- return Ne(
144
- t.subscribe,
145
- () => t.getState().totalViolations,
146
- () => t.getState().totalViolations
206
+ return Te(
207
+ i.subscribe,
208
+ () => i.getState().totalViolations,
209
+ () => i.getState().totalViolations
147
210
  );
148
- }, We = () => {
149
- const t = re(ne);
150
- if (!t)
211
+ }, tt = () => {
212
+ const i = re(ne);
213
+ if (!i)
151
214
  throw new Error(
152
215
  "useProctoringActions must be used within a ProctoringProvider"
153
216
  );
154
217
  return {
155
- addViolation: t.addViolation,
156
- clearViolations: t.clearViolations
218
+ addViolation: i.addViolation,
219
+ clearViolations: i.clearViolations
157
220
  };
158
- }, Ce = je(
221
+ }, Ae = Ee(
159
222
  null
160
223
  );
161
- function Ve({
162
- config: t = {},
224
+ function it({
225
+ config: i = {},
163
226
  children: r
164
227
  }) {
165
228
  var s, n, o, a;
166
- const i = {
229
+ const t = {
167
230
  api: {
168
231
  ...$.api,
169
- ...t.api,
232
+ ...i.api,
170
233
  retryConfig: {
171
234
  ...$.api.retryConfig,
172
- ...(s = t.api) == null ? void 0 : s.retryConfig
235
+ ...(s = i.api) == null ? void 0 : s.retryConfig
173
236
  }
174
237
  },
175
238
  ui: {
176
239
  ...$.ui,
177
- ...t.ui
240
+ ...i.ui
178
241
  },
179
242
  interview: {
180
243
  ...$.interview,
181
- ...t.interview,
244
+ ...i.interview,
182
245
  timers: {
183
246
  ...$.interview.timers,
184
- ...(n = t.interview) == null ? void 0 : n.timers
247
+ ...(n = i.interview) == null ? void 0 : n.timers
185
248
  },
186
249
  stt: {
187
250
  ...$.interview.stt,
188
- ...(o = t.interview) == null ? void 0 : o.stt
251
+ ...(o = i.interview) == null ? void 0 : o.stt
189
252
  },
190
253
  tts: {
191
254
  ...$.interview.tts,
192
- ...(a = t.interview) == null ? void 0 : a.tts
255
+ ...(a = i.interview) == null ? void 0 : a.tts
193
256
  }
194
257
  }
195
258
  };
196
- return /* @__PURE__ */ e.jsx(Ce.Provider, { value: i, children: /* @__PURE__ */ e.jsx(ze, { children: r }) });
259
+ return /* @__PURE__ */ e.jsx(Ae.Provider, { value: t, children: /* @__PURE__ */ e.jsx(Xe, { children: r }) });
197
260
  }
198
261
  function ae() {
199
- const t = re(Ce);
200
- if (!t)
262
+ const i = re(Ae);
263
+ if (!i)
201
264
  throw new Error(
202
265
  "useInterviewConfig must be used within an InterviewWidgetProvider. Wrap your component tree with <InterviewWidgetProvider config={...}>"
203
266
  );
204
- return t;
267
+ return i;
205
268
  }
206
- function Se() {
269
+ function Me() {
207
270
  return ae().api || $.api;
208
271
  }
209
272
  function Z() {
210
273
  return ae().ui || $.ui;
211
274
  }
212
- function He() {
275
+ function rt() {
213
276
  return ae().interview || $.interview;
214
277
  }
215
- const Ie = ({
216
- className: t,
278
+ const De = ({
279
+ className: i,
217
280
  ...r
218
281
  }) => /* @__PURE__ */ e.jsx("div", { children: /* @__PURE__ */ e.jsxs(
219
282
  "svg",
@@ -227,7 +290,7 @@ const Ie = ({
227
290
  strokeWidth: "2",
228
291
  strokeLinecap: "round",
229
292
  strokeLinejoin: "round",
230
- className: `iw-animate-spin ${t}`,
293
+ className: `iw-animate-spin ${i}`,
231
294
  ...r,
232
295
  children: [
233
296
  /* @__PURE__ */ e.jsx("path", { stroke: "none", d: "M0 0h24v24H0z", fill: "none" }),
@@ -241,17 +304,17 @@ const Ie = ({
241
304
  /* @__PURE__ */ e.jsx("path", { d: "M7.75 7.75l-2.15 -2.15" })
242
305
  ]
243
306
  }
244
- ) }), Re = ({
245
- children: t,
307
+ ) }), _e = ({
308
+ children: i,
246
309
  variant: r = "primary",
247
- size: i = "md",
310
+ size: t = "md",
248
311
  fullWidth: s = !1,
249
312
  isLoading: n = !1,
250
313
  disabled: o,
251
314
  className: a = "",
252
315
  ...l
253
316
  }) => {
254
- const d = "iw-inline-flex iw-items-center iw-justify-center iw-rounded-md iw-font-medium iw-transition-colors iw-focus:outline-none iw-focus:ring-2 iw-focus:ring-primary-500 iw-focus:ring-offset-2", w = {
317
+ const d = "iw-inline-flex iw-items-center iw-justify-center iw-rounded-md iw-font-medium iw-transition-colors iw-focus:outline-none iw-focus:ring-2 iw-focus:ring-primary-500 iw-focus:ring-offset-2", c = {
255
318
  primary: "iw-bg-primary-600 iw-text-white iw-hover:bg-primary-700 iw-border iw-border-transparent",
256
319
  secondary: "iw-bg-primary-100 iw-text-primary-700 iw-hover:bg-primary-200 iw-border iw-border-transparent",
257
320
  outline: "iw-bg-transparent iw-text-primary-700 iw-border iw-border-primary-500 iw-hover:bg-primary-50",
@@ -265,52 +328,52 @@ const Ie = ({
265
328
  return /* @__PURE__ */ e.jsxs(
266
329
  "button",
267
330
  {
268
- className: `${d} ${w[r]} ${u[i]} ${m} ${h} ${a}`,
331
+ className: `${d} ${c[r]} ${u[t]} ${m} ${h} ${a}`,
269
332
  disabled: o || n,
270
333
  ...l,
271
334
  children: [
272
- n && /* @__PURE__ */ e.jsx(Ie, { height: 16, width: 16, style: { marginRight: "3px" } }),
273
- t
335
+ n && /* @__PURE__ */ e.jsx(De, { height: 16, width: 16, style: { marginRight: "3px" } }),
336
+ i
274
337
  ]
275
338
  }
276
339
  );
277
340
  };
278
- function Qe(t) {
279
- const r = /^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(t);
341
+ function st(i) {
342
+ const r = /^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(i);
280
343
  return r ? {
281
344
  r: parseInt(r[1], 16),
282
345
  g: parseInt(r[2], 16),
283
346
  b: parseInt(r[3], 16)
284
347
  } : null;
285
348
  }
286
- function Ye(t, r, i) {
287
- return "#" + [t, r, i].map((s) => {
349
+ function nt(i, r, t) {
350
+ return "#" + [i, r, t].map((s) => {
288
351
  const n = Math.round(s).toString(16);
289
352
  return n.length === 1 ? "0" + n : n;
290
353
  }).join("");
291
354
  }
292
- function Me(t, r) {
293
- const i = Qe(t);
294
- if (!i) return t;
295
- const s = i.r + (255 - i.r) * r, n = i.g + (255 - i.g) * r, o = i.b + (255 - i.b) * r;
296
- return Ye(s, n, o);
355
+ function Pe(i, r) {
356
+ const t = st(i);
357
+ if (!t) return i;
358
+ const s = t.r + (255 - t.r) * r, n = t.g + (255 - t.g) * r, o = t.b + (255 - t.b) * r;
359
+ return nt(s, n, o);
297
360
  }
298
- function Ke(t, r = 0.8) {
361
+ function at(i, r = 0.8) {
299
362
  return {
300
- background: `linear-gradient(to bottom, ${Me(t, r)}, #ffffff)`,
363
+ background: `linear-gradient(to bottom, ${Pe(i, r)}, #ffffff)`,
301
364
  color: "#1f2937"
302
365
  };
303
366
  }
304
- function Je(t) {
305
- return new Promise((r) => setTimeout(r, t));
367
+ function ot(i) {
368
+ return new Promise((r) => setTimeout(r, i));
306
369
  }
307
- function Ae(t) {
308
- return `linear-gradient(to left, ${Me(t, 0.4)}, ${t})`;
370
+ function Fe(i) {
371
+ return `linear-gradient(to left, ${Pe(i, 0.4)}, ${i})`;
309
372
  }
310
- const Xe = () => Math.random().toString(36).substring(2, 15) + Math.random().toString(36).substring(2, 15);
311
- function Ze(t) {
373
+ const lt = () => Math.random().toString(36).substring(2, 15) + Math.random().toString(36).substring(2, 15);
374
+ function ct(i) {
312
375
  try {
313
- const r = t.split(".");
376
+ const r = i.split(".");
314
377
  if (r.length !== 3 || !r[1])
315
378
  throw new Error("Invalid JWT token");
316
379
  const s = r[1].replace(/-/g, "+").replace(/_/g, "/"), n = s.padEnd(
@@ -322,7 +385,7 @@ function Ze(t) {
322
385
  return console.error("Error decoding JWT:", r), null;
323
386
  }
324
387
  }
325
- const De = (t) => /* @__PURE__ */ e.jsxs(
388
+ const Le = (i) => /* @__PURE__ */ e.jsxs(
326
389
  "svg",
327
390
  {
328
391
  xmlns: "http://www.w3.org/2000/svg",
@@ -334,13 +397,13 @@ const De = (t) => /* @__PURE__ */ e.jsxs(
334
397
  strokeWidth: "2",
335
398
  strokeLinecap: "round",
336
399
  strokeLinejoin: "round",
337
- ...t,
400
+ ...i,
338
401
  children: [
339
402
  /* @__PURE__ */ e.jsx("path", { d: "M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z" }),
340
403
  /* @__PURE__ */ e.jsx("path", { d: "m9 12 2 2 4-4" })
341
404
  ]
342
405
  }
343
- ), Pe = (t) => /* @__PURE__ */ e.jsxs(
406
+ ), $e = (i) => /* @__PURE__ */ e.jsxs(
344
407
  "svg",
345
408
  {
346
409
  xmlns: "http://www.w3.org/2000/svg",
@@ -352,14 +415,14 @@ const De = (t) => /* @__PURE__ */ e.jsxs(
352
415
  strokeWidth: "2",
353
416
  strokeLinecap: "round",
354
417
  strokeLinejoin: "round",
355
- ...t,
418
+ ...i,
356
419
  children: [
357
420
  /* @__PURE__ */ e.jsx("rect", { width: "20", height: "14", x: "2", y: "3", rx: "2" }),
358
421
  /* @__PURE__ */ e.jsx("line", { x1: "8", x2: "16", y1: "21", y2: "21" }),
359
422
  /* @__PURE__ */ e.jsx("line", { x1: "12", x2: "12", y1: "17", y2: "21" })
360
423
  ]
361
424
  }
362
- ), et = (t) => /* @__PURE__ */ e.jsxs(
425
+ ), dt = (i) => /* @__PURE__ */ e.jsxs(
363
426
  "svg",
364
427
  {
365
428
  xmlns: "http://www.w3.org/2000/svg",
@@ -371,56 +434,56 @@ const De = (t) => /* @__PURE__ */ e.jsxs(
371
434
  strokeWidth: "2",
372
435
  strokeLinecap: "round",
373
436
  strokeLinejoin: "round",
374
- ...t,
437
+ ...i,
375
438
  children: [
376
439
  /* @__PURE__ */ e.jsx("path", { stroke: "none", d: "M0 0h24v24H0z", fill: "none" }),
377
440
  /* @__PURE__ */ e.jsx("path", { d: "M15 8a5 5 0 0 1 0 8" }),
378
441
  /* @__PURE__ */ e.jsx("path", { d: "M6 15h-2a1 1 0 0 1 -1 -1v-4a1 1 0 0 1 1 -1h2l3.5 -4.5a.8 .8 0 0 1 1.5 .5v14a.8 .8 0 0 1 -1.5 .5l-3.5 -4.5" })
379
442
  ]
380
443
  }
381
- ), W = (t) => {
382
- const { baseColor: r, borderRadius: i } = Z(), { loading: s, children: n, ...o } = t;
444
+ ), V = (i) => {
445
+ const { baseColor: r, borderRadius: t } = Z(), { loading: s, children: n, ...o } = i;
383
446
  return /* @__PURE__ */ e.jsx(
384
- Re,
447
+ _e,
385
448
  {
386
449
  style: {
387
- background: Ae(r),
388
- borderRadius: i
450
+ background: Fe(r),
451
+ borderRadius: t
389
452
  },
390
453
  ...o,
391
- children: s ? /* @__PURE__ */ e.jsx(Ie, {}) : n
454
+ children: s ? /* @__PURE__ */ e.jsx(De, {}) : n
392
455
  }
393
456
  );
394
- }, tt = [
457
+ }, wt = [
395
458
  "Do not refresh or reload the page during your assessment",
396
459
  "Refrain from switching tabs or opening other applications while the session is in progress",
397
460
  "Ensure your face remains clearly visible on camera at all times",
398
461
  "Avoid frequent distractions or leaving your seat during the session",
399
462
  "Do not disable or interfere with audio/video monitoring"
400
- ], it = ({
401
- isOpen: t,
463
+ ], ut = ({
464
+ isOpen: i,
402
465
  onStart: r,
403
- onClose: i
466
+ onClose: t
404
467
  }) => {
405
- var M;
406
- const s = T(null), n = T(null), { baseColor: o, borderRadius: a } = Z(), [l, d] = k(!1), [w, u] = k(null), [h, m] = k(!1), c = o ?? "#2563eb", x = Ae(c), y = a ?? 18, j = (g, I) => g.startsWith("#") && g.length === 7 ? `${g}${I}` : g, f = [
468
+ var A;
469
+ const s = T(null), n = T(null), { baseColor: o, borderRadius: a } = Z(), [l, d] = k(!1), [c, u] = k(null), [h, m] = k(!1), w = o ?? "#2563eb", f = Fe(w), v = a ?? 18, j = (g, I) => g.startsWith("#") && g.length === 7 ? `${g}${I}` : g, x = [
407
470
  `radial-gradient(120% 85% at 50% 125%, ${j(
408
- c,
471
+ w,
409
472
  "34"
410
473
  )} 0%, transparent 70%)`,
411
474
  `radial-gradient(90% 70% at 10% 130%, ${j(
412
- c,
475
+ w,
413
476
  "24"
414
477
  )} 0%, transparent 72%)`,
415
478
  `radial-gradient(90% 70% at 90% 130%, ${j(
416
- c,
479
+ w,
417
480
  "24"
418
481
  )} 0%, transparent 72%)`,
419
482
  `repeating-linear-gradient(135deg, ${j(
420
- c,
483
+ w,
421
484
  "14"
422
485
  )} 0, ${j(
423
- c,
486
+ w,
424
487
  "14"
425
488
  )} 16px, transparent 16px, transparent 32px)`
426
489
  ].join(", "), E = l ? {
@@ -450,22 +513,22 @@ const De = (t) => /* @__PURE__ */ e.jsxs(
450
513
  toneClass: "iw-bg-rose-50 iw-text-rose-600",
451
514
  cameraCopy: "Grant camera access to continue with the interview.",
452
515
  micCopy: "Enable microphone access so we can capture your answers."
453
- }, v = [
516
+ }, y = [
454
517
  {
455
518
  label: "Camera feed",
456
519
  description: S.cameraCopy,
457
520
  status: S.badge,
458
521
  toneClass: S.toneClass,
459
- Icon: Pe
522
+ Icon: $e
460
523
  },
461
524
  {
462
525
  label: "Microphone input",
463
526
  description: S.micCopy,
464
527
  status: S.badge,
465
528
  toneClass: S.toneClass,
466
- Icon: et
529
+ Icon: dt
467
530
  }
468
- ], F = () => {
531
+ ], P = () => {
469
532
  n.current && (n.current.getTracks().forEach((g) => g.stop()), n.current = null);
470
533
  }, b = async () => {
471
534
  m(!0), u(null);
@@ -484,23 +547,23 @@ const De = (t) => /* @__PURE__ */ e.jsxs(
484
547
  }
485
548
  };
486
549
  if (C(() => {
487
- if (!t) {
488
- F();
550
+ if (!i) {
551
+ P();
489
552
  return;
490
553
  }
491
554
  return b(), () => {
492
- F();
555
+ P();
493
556
  };
494
- }, [t]), !t) return null;
557
+ }, [i]), !i) return null;
495
558
  const D = () => {
496
- r(), F();
559
+ r(), P();
497
560
  };
498
561
  return /* @__PURE__ */ e.jsx("div", { className: "iw-fixed iw-inset-0 iw-z-50 iw-flex iw-items-center iw-justify-center iw-bg-gray-900/25 iw-backdrop-blur-md iw-p-4", children: /* @__PURE__ */ e.jsxs("div", { className: " iw-w-full iw-max-w-[920px] iw-max-h-[96vh] iw-overflow-auto iw-rounded-3xl iw-bg-white iw-shadow-[0_40px_80px_-28px_rgba(15,23,42,0.25)]", children: [
499
562
  /* @__PURE__ */ e.jsxs(
500
563
  "div",
501
564
  {
502
565
  className: "iw-relative iw-overflow-hidden",
503
- style: { background: x },
566
+ style: { background: f },
504
567
  children: [
505
568
  /* @__PURE__ */ e.jsx(
506
569
  "div",
@@ -534,7 +597,7 @@ const De = (t) => /* @__PURE__ */ e.jsxs(
534
597
  ),
535
598
  /* @__PURE__ */ e.jsxs("div", { className: "iw-relative iw-grid md:iw-grid-cols-[minmax(0,1fr)_auto] iw-items-start iw-gap-6 iw-px-6 iw-py-7", children: [
536
599
  /* @__PURE__ */ e.jsx("div", { className: "iw-flex iw-flex-col iw-gap-4 iw-text-white", children: /* @__PURE__ */ e.jsxs("div", { className: "iw-flex iw-items-start iw-gap-4", children: [
537
- /* @__PURE__ */ e.jsx("div", { className: "iw-flex iw-h-12 iw-w-12 iw-items-center iw-justify-center iw-rounded-2xl iw-bg-white/15 iw-shadow-inner", children: /* @__PURE__ */ e.jsx(De, { className: "iw-h-6 iw-w-6" }) }),
600
+ /* @__PURE__ */ e.jsx("div", { className: "iw-flex iw-h-12 iw-w-12 iw-items-center iw-justify-center iw-rounded-2xl iw-bg-white/15 iw-shadow-inner", children: /* @__PURE__ */ e.jsx(Le, { className: "iw-h-6 iw-w-6" }) }),
538
601
  /* @__PURE__ */ e.jsxs("div", { children: [
539
602
  /* @__PURE__ */ e.jsx("p", { className: "iw-text-[11px] iw-font-medium iw-uppercase iw-tracking-wide iw-text-white/70", children: "Pre-interview checklist" }),
540
603
  /* @__PURE__ */ e.jsx("h2", { className: "iw-mt-1 iw-text-xl iw-font-semibold iw-leading-tight", children: "Final checks before you go live" }),
@@ -556,13 +619,13 @@ const De = (t) => /* @__PURE__ */ e.jsxs(
556
619
  ]
557
620
  }
558
621
  ) }),
559
- i && /* @__PURE__ */ e.jsx(
622
+ t && /* @__PURE__ */ e.jsx(
560
623
  "button",
561
624
  {
562
625
  "aria-label": "Close",
563
626
  className: "iw-absolute iw-top-5 iw-right-5 iw-text-white/70 transition-colors hover:iw-text-white",
564
627
  onClick: () => {
565
- F(), i == null || i();
628
+ P(), t == null || t();
566
629
  },
567
630
  children: "✕"
568
631
  }
@@ -578,7 +641,7 @@ const De = (t) => /* @__PURE__ */ e.jsxs(
578
641
  /* @__PURE__ */ e.jsx("h3", { className: "iw-text-sm iw-font-semibold iw-text-slate-900", children: "Proctoring guidelines" }),
579
642
  /* @__PURE__ */ e.jsx("span", { className: "iw-text-[11px] iw-font-medium iw-uppercase iw-tracking-wide iw-text-slate-400", children: "Required" })
580
643
  ] }),
581
- /* @__PURE__ */ e.jsx("ul", { className: "iw-mt-5 iw-flex iw-flex-col iw-gap-4", children: tt.map((g, I) => /* @__PURE__ */ e.jsx(
644
+ /* @__PURE__ */ e.jsx("ul", { className: "iw-mt-5 iw-flex iw-flex-col iw-gap-4", children: wt.map((g, I) => /* @__PURE__ */ e.jsx(
582
645
  "li",
583
646
  {
584
647
  className: "iw-group iw-overflow-hidden iw-rounded-xl iw-border iw-border-slate-100 iw-bg-slate-50/60 iw-p-4 iw-transition-all hover:iw-border-slate-200 hover:iw-bg-white",
@@ -587,7 +650,7 @@ const De = (t) => /* @__PURE__ */ e.jsxs(
587
650
  "span",
588
651
  {
589
652
  className: "iw-flex iw-h-8 iw-w-8 iw-flex-none iw-items-center iw-justify-center iw-rounded-full iw-text-sm iw-font-semibold iw-text-white",
590
- style: { background: x },
653
+ style: { background: f },
591
654
  children: I + 1
592
655
  }
593
656
  ),
@@ -602,7 +665,7 @@ const De = (t) => /* @__PURE__ */ e.jsxs(
602
665
  "div",
603
666
  {
604
667
  className: "iw-relative iw-flex iw-flex-col iw-gap-6 iw-overflow-hidden iw-rounded-3xl iw-bg-white ",
605
- style: { borderRadius: y },
668
+ style: { borderRadius: v },
606
669
  children: [
607
670
  /* @__PURE__ */ e.jsx("div", { className: "iw-relative iw-z-10 iw-rounded-2xl iw-border iw-border-slate-200 iw-bg-slate-50/80 iw-p-3", children: /* @__PURE__ */ e.jsx(
608
671
  "video",
@@ -614,13 +677,13 @@ const De = (t) => /* @__PURE__ */ e.jsxs(
614
677
  className: "iw-h-64 iw-w-full iw-rounded-2xl iw-object-cover",
615
678
  style: {
616
679
  transform: "scaleX(-1)",
617
- borderRadius: y
680
+ borderRadius: v
618
681
  }
619
682
  }
620
683
  ) }),
621
684
  /* @__PURE__ */ e.jsxs("div", { className: "iw-relative iw-grid iw-grid-cols-2 iw-gap-4 iw-px-1", children: [
622
685
  /* @__PURE__ */ e.jsx(
623
- Re,
686
+ _e,
624
687
  {
625
688
  onClick: b,
626
689
  disabled: h,
@@ -628,21 +691,21 @@ const De = (t) => /* @__PURE__ */ e.jsxs(
628
691
  size: "sm",
629
692
  className: "iw-font-medium",
630
693
  style: {
631
- borderColor: c,
632
- borderRadius: y,
633
- color: c
694
+ borderColor: w,
695
+ borderRadius: v,
696
+ color: w
634
697
  },
635
698
  children: l ? "Recheck permissions" : "Enable camera & mic"
636
699
  }
637
700
  ),
638
701
  /* @__PURE__ */ e.jsx(
639
- W,
702
+ V,
640
703
  {
641
704
  onClick: D,
642
705
  disabled: !l,
643
706
  className: "iw-h-10 iw-px-6 iw-text-sm",
644
707
  style: {
645
- backgroundColor: c
708
+ backgroundColor: w
646
709
  },
647
710
  children: "Proceed"
648
711
  }
@@ -651,8 +714,8 @@ const De = (t) => /* @__PURE__ */ e.jsxs(
651
714
  ]
652
715
  }
653
716
  ),
654
- /* @__PURE__ */ e.jsx("ul", { className: "iw-grid sm:iw-grid-cols-1 iw-gap-3", children: v.map(
655
- ({ Icon: g, label: I, description: L, status: z, toneClass: U }) => /* @__PURE__ */ e.jsx(
717
+ /* @__PURE__ */ e.jsx("ul", { className: "iw-grid sm:iw-grid-cols-1 iw-gap-3", children: y.map(
718
+ ({ Icon: g, label: I, description: L, status: B, toneClass: q }) => /* @__PURE__ */ e.jsx(
656
719
  "li",
657
720
  {
658
721
  className: "iw-rounded-2xl iw-border iw-border-slate-200/65 iw-bg-white iw-p-4 iw-shadow-sm iw-transition-all hover:iw-border-slate-200",
@@ -664,8 +727,8 @@ const De = (t) => /* @__PURE__ */ e.jsxs(
664
727
  /* @__PURE__ */ e.jsx(
665
728
  "span",
666
729
  {
667
- className: `iw-rounded-full iw-px-3 iw-py-1 iw-text-[11px] iw-font-semibold ${U}`,
668
- children: z
730
+ className: `iw-rounded-full iw-px-3 iw-py-1 iw-text-[11px] iw-font-semibold ${q}`,
731
+ children: B
669
732
  }
670
733
  )
671
734
  ] }),
@@ -676,8 +739,8 @@ const De = (t) => /* @__PURE__ */ e.jsxs(
676
739
  I
677
740
  )
678
741
  ) }),
679
- w && /* @__PURE__ */ e.jsx("div", { className: "iw-rounded-lg iw-border iw-border-rose-200 iw-bg-rose-50 iw-px-3 iw-py-2 iw-text-xs iw-text-rose-600", children: w }),
680
- !((M = navigator.mediaDevices) != null && M.getUserMedia) && /* @__PURE__ */ e.jsx("div", { className: "iw-rounded-lg iw-border iw-border-amber-200 iw-bg-amber-50 iw-px-3 iw-py-2 iw-text-xs iw-text-amber-700", children: "Your browser does not support media devices. Please use a modern browser like Chrome, Edge, or Firefox." })
742
+ c && /* @__PURE__ */ e.jsx("div", { className: "iw-rounded-lg iw-border iw-border-rose-200 iw-bg-rose-50 iw-px-3 iw-py-2 iw-text-xs iw-text-rose-600", children: c }),
743
+ !((A = navigator.mediaDevices) != null && A.getUserMedia) && /* @__PURE__ */ e.jsx("div", { className: "iw-rounded-lg iw-border iw-border-amber-200 iw-bg-amber-50 iw-px-3 iw-py-2 iw-text-xs iw-text-amber-700", children: "Your browser does not support media devices. Please use a modern browser like Chrome, Edge, or Firefox." })
681
744
  ] })
682
745
  ] }),
683
746
  /* @__PURE__ */ e.jsx("div", { className: " iw-rounded-2xl iw-border iw-border-dashed iw-border-slate-200 iw-bg-slate-50/85 iw-px-5 iw-py-4 iw-text-center", children: /* @__PURE__ */ e.jsx("div", { className: "iw-text-xs iw-text-slate-500", children: "Your session is monitored to protect exam integrity. Continuing confirms you have reviewed and accept these safeguards." }) }),
@@ -687,7 +750,7 @@ const De = (t) => /* @__PURE__ */ e.jsxs(
687
750
  "aria-hidden": !0,
688
751
  className: "iw-pointer-events-none iw-absolute iw-inset-x-0 iw-bottom-1 iw-h-20",
689
752
  style: {
690
- backgroundImage: f,
753
+ backgroundImage: x,
691
754
  backgroundSize: "100% 120%, 100% 120%, 100% 120%, 32px 32px",
692
755
  backgroundPosition: "center bottom, left 95% bottom, right 95% bottom, center bottom",
693
756
  backgroundRepeat: "no-repeat, no-repeat, no-repeat, repeat",
@@ -701,12 +764,12 @@ const De = (t) => /* @__PURE__ */ e.jsxs(
701
764
  ] })
702
765
  ] }) });
703
766
  };
704
- var P = /* @__PURE__ */ ((t) => (t.IDLE = "idle", t.FETCHING_QUESTION = "fetching_question", t.READING_QUESTION = "reading_question", t.THINKING = "thinking", t.ANSWERING = "answering", t.TRANSCRIBING = "transcribing", t.EDITING = "editing", t.SUBMITTING = "submitting", t.COMPLETED = "completed", t))(P || {});
705
- const rt = {
767
+ var _ = /* @__PURE__ */ ((i) => (i.IDLE = "idle", i.FETCHING_QUESTION = "fetching_question", i.READING_QUESTION = "reading_question", i.THINKING = "thinking", i.ANSWERING = "answering", i.TRANSCRIBING = "transcribing", i.EDITING = "editing", i.SUBMITTING = "submitting", i.COMPLETED = "completed", i))(_ || {});
768
+ const ht = {
706
769
  thinkingDuration: 30,
707
770
  answeringDuration: 120,
708
771
  editingDuration: 30
709
- }, st = {
772
+ }, mt = {
710
773
  idle: {
711
774
  next: "fetching_question"
712
775
  /* FETCHING_QUESTION */
@@ -735,14 +798,14 @@ const rt = {
735
798
  /* COMPLETED */
736
799
  }
737
800
  };
738
- class nt {
739
- constructor(r = {}, i = {}) {
740
- _(this, "config");
741
- _(this, "state");
742
- _(this, "phaseIntervalId", null);
743
- _(this, "globalIntervalId", null);
744
- _(this, "callbacks");
745
- this.config = { ...rt, ...r }, this.callbacks = i, this.state = {
801
+ class gt {
802
+ constructor(r = {}, t = {}) {
803
+ F(this, "config");
804
+ F(this, "state");
805
+ F(this, "phaseIntervalId", null);
806
+ F(this, "globalIntervalId", null);
807
+ F(this, "callbacks");
808
+ this.config = { ...ht, ...r }, this.callbacks = t, this.state = {
746
809
  phase: "idle",
747
810
  currentPhaseTimeRemaining: 0,
748
811
  totalTimeElapsed: 0,
@@ -765,18 +828,18 @@ class nt {
765
828
  * Move to next phase
766
829
  */
767
830
  nextPhase() {
768
- const r = this.state.phase, i = st[r];
769
- if (!i) return;
770
- this.stopPhaseTimer(), this.state.phase = i.next;
771
- const s = this.getDurationForPhase(i.next);
831
+ const r = this.state.phase, t = mt[r];
832
+ if (!t) return;
833
+ this.stopPhaseTimer(), this.state.phase = t.next;
834
+ const s = this.getDurationForPhase(t.next);
772
835
  s > 0 ? (this.state.currentPhaseTimeRemaining = s, this.startPhaseTimer()) : this.state.currentPhaseTimeRemaining = 0, this.notifyChange();
773
836
  }
774
837
  /**
775
838
  * Manually complete the interview
776
839
  */
777
840
  completeInterview() {
778
- var r, i;
779
- this.stopGlobalTimer(), this.stopPhaseTimer(), this.state.phase = "completed", (i = (r = this.callbacks).onInterviewEnd) == null || i.call(r), this.notifyChange();
841
+ var r, t;
842
+ this.stopGlobalTimer(), this.stopPhaseTimer(), this.state.phase = "completed", (t = (r = this.callbacks).onInterviewEnd) == null || t.call(r), this.notifyChange();
780
843
  }
781
844
  /**
782
845
  * Cleanup
@@ -804,8 +867,8 @@ class nt {
804
867
  */
805
868
  startGlobalTimer() {
806
869
  this.globalIntervalId = setInterval(() => {
807
- var r, i;
808
- this.state.totalTimeElapsed++, (i = (r = this.callbacks).onTick) == null || i.call(r, this.getState());
870
+ var r, t;
871
+ this.state.totalTimeElapsed++, (t = (r = this.callbacks).onTick) == null || t.call(r, this.getState());
809
872
  }, 1e3);
810
873
  }
811
874
  /**
@@ -832,38 +895,38 @@ class nt {
832
895
  * Notify phase change
833
896
  */
834
897
  notifyChange() {
835
- var r, i;
836
- (i = (r = this.callbacks).onPhaseChange) == null || i.call(r, this.state.phase, this.getState());
898
+ var r, t;
899
+ (t = (r = this.callbacks).onPhaseChange) == null || t.call(r, this.state.phase, this.getState());
837
900
  }
838
901
  }
839
- function at(t = {}) {
840
- const { config: r = {}, callbacks: i = {} } = t, s = T(null);
841
- s.current || (s.current = new nt(r, {}));
902
+ function ft(i = {}) {
903
+ const { config: r = {}, callbacks: t = {} } = i, s = T(null);
904
+ s.current || (s.current = new gt(r, {}));
842
905
  const n = s.current, [o, a] = k(n.getState()), l = N(() => {
843
906
  a(n.getState());
844
907
  }, [n]);
845
908
  C(() => {
846
909
  const h = {
847
- onPhaseChange: (m, c) => {
848
- var x;
849
- l(), (x = i.onPhaseChange) == null || x.call(i, m, c);
910
+ onPhaseChange: (m, w) => {
911
+ var f;
912
+ l(), (f = t.onPhaseChange) == null || f.call(t, m, w);
850
913
  },
851
914
  onTick: (m) => {
852
- var c;
853
- l(), (c = i.onTick) == null || c.call(i, m);
915
+ var w;
916
+ l(), (w = t.onTick) == null || w.call(t, m);
854
917
  },
855
918
  onInterviewEnd: () => {
856
919
  var m;
857
- l(), (m = i.onInterviewEnd) == null || m.call(i);
920
+ l(), (m = t.onInterviewEnd) == null || m.call(t);
858
921
  }
859
922
  };
860
923
  n.callbacks = h;
861
- }, [n, i, l]), C(() => () => {
924
+ }, [n, t, l]), C(() => () => {
862
925
  n.destroy();
863
926
  }, [n]);
864
927
  const d = N(() => {
865
928
  n.startQuestion(), l();
866
- }, [n, l]), w = N(() => {
929
+ }, [n, l]), c = N(() => {
867
930
  n.nextPhase(), l();
868
931
  }, [n, l]), u = N(() => {
869
932
  n.completeInterview(), l();
@@ -871,22 +934,22 @@ function at(t = {}) {
871
934
  return {
872
935
  state: o,
873
936
  startQuestion: d,
874
- nextPhase: w,
937
+ nextPhase: c,
875
938
  completeInterview: u,
876
939
  timerService: n
877
940
  };
878
941
  }
879
- function ot(t, r = {}) {
880
- const [i, s] = k({
942
+ function xt(i, r = {}) {
943
+ const [t, s] = k({
881
944
  data: null,
882
945
  loading: !1,
883
946
  error: null
884
947
  }), n = N(
885
948
  async (...o) => {
886
- var a, l, d, w;
949
+ var a, l, d, c;
887
950
  s((u) => ({ ...u, loading: !0, error: null }));
888
951
  try {
889
- const u = await t(...o);
952
+ const u = await i(...o);
890
953
  s((h) => ({
891
954
  ...h,
892
955
  data: u,
@@ -905,77 +968,77 @@ function ot(t, r = {}) {
905
968
  ...m,
906
969
  loading: !1,
907
970
  error: h
908
- })), (d = r.onError) == null || d.call(r, h), (w = r.onSettled) == null || w.call(r, null, h);
971
+ })), (d = r.onError) == null || d.call(r, h), (c = r.onSettled) == null || c.call(r, null, h);
909
972
  }
910
973
  },
911
- [t, r]
974
+ [i, r]
912
975
  );
913
976
  return {
914
- ...i,
977
+ ...t,
915
978
  execute: n
916
979
  };
917
980
  }
918
- const lt = (t) => {
919
- const [r, i] = k(null), [s, n] = k(!1), o = document, a = () => !!(o.fullscreenEnabled || o.webkitFullscreenEnabled || o.mozFullScreenEnabled || o.msFullscreenEnabled), l = () => o.fullscreenElement || o.webkitFullscreenElement || o.mozFullScreenElement || o.msFullscreenElement, d = async (c) => {
920
- var x;
981
+ const pt = (i) => {
982
+ const [r, t] = k(null), [s, n] = k(!1), o = document, a = () => !!(o.fullscreenEnabled || o.webkitFullscreenEnabled || o.mozFullScreenEnabled || o.msFullscreenEnabled), l = () => o.fullscreenElement || o.webkitFullscreenElement || o.mozFullScreenElement || o.msFullscreenElement, d = async (w) => {
983
+ var f;
921
984
  try {
922
985
  if (!a())
923
986
  throw new Error("Fullscreen is not supported in this environment");
924
- c.requestFullscreen ? await c.requestFullscreen() : c.webkitRequestFullscreen ? await c.webkitRequestFullscreen() : c.mozRequestFullScreen ? await c.mozRequestFullScreen() : c.msRequestFullscreen && await c.msRequestFullscreen();
925
- } catch (y) {
987
+ w.requestFullscreen ? await w.requestFullscreen() : w.webkitRequestFullscreen ? await w.webkitRequestFullscreen() : w.mozRequestFullScreen ? await w.mozRequestFullScreen() : w.msRequestFullscreen && await w.msRequestFullscreen();
988
+ } catch (v) {
926
989
  const j = {
927
990
  name: "FullscreenError",
928
- message: y instanceof Error ? y.message : "Failed to enter fullscreen"
991
+ message: v instanceof Error ? v.message : "Failed to enter fullscreen"
929
992
  };
930
- i(j), (x = t == null ? void 0 : t.onError) == null || x.call(t, j);
993
+ t(j), (f = i == null ? void 0 : i.onError) == null || f.call(i, j);
931
994
  }
932
- }, w = async () => {
933
- var c;
995
+ }, c = async () => {
996
+ var w;
934
997
  try {
935
998
  o.exitFullscreen ? await o.exitFullscreen() : o.webkitExitFullscreen ? await o.webkitExitFullscreen() : o.mozCancelFullScreen ? await o.mozCancelFullScreen() : o.msExitFullscreen && await o.msExitFullscreen();
936
- } catch (x) {
937
- const y = {
999
+ } catch (f) {
1000
+ const v = {
938
1001
  name: "FullscreenError",
939
- message: x instanceof Error ? x.message : "Failed to exit fullscreen"
1002
+ message: f instanceof Error ? f.message : "Failed to exit fullscreen"
940
1003
  };
941
- i(y), (c = t == null ? void 0 : t.onError) == null || c.call(t, y);
1004
+ t(v), (w = i == null ? void 0 : i.onError) == null || w.call(i, v);
942
1005
  }
943
1006
  }, u = N(() => {
944
- var x;
945
- const c = !!l();
946
- n(c), (x = t == null ? void 0 : t.onFullScreenChange) == null || x.call(t, c);
947
- }, [t]);
1007
+ var f;
1008
+ const w = !!l();
1009
+ n(w), (f = i == null ? void 0 : i.onFullScreenChange) == null || f.call(i, w);
1010
+ }, [i]);
948
1011
  C(() => {
949
- const c = [
1012
+ const w = [
950
1013
  "fullscreenchange",
951
1014
  "webkitfullscreenchange",
952
1015
  "mozfullscreenchange",
953
1016
  "MSFullscreenChange"
954
1017
  ];
955
- return c.forEach((x) => {
956
- document.addEventListener(x, u);
1018
+ return w.forEach((f) => {
1019
+ document.addEventListener(f, u);
957
1020
  }), () => {
958
- c.forEach((x) => {
959
- document.removeEventListener(x, u);
1021
+ w.forEach((f) => {
1022
+ document.removeEventListener(f, u);
960
1023
  });
961
1024
  };
962
1025
  }, [u]);
963
- const h = async (c) => {
964
- i(null);
965
- const x = c ?? document.documentElement;
966
- await d(x);
1026
+ const h = async (w) => {
1027
+ t(null);
1028
+ const f = w ?? document.documentElement;
1029
+ await d(f);
967
1030
  };
968
1031
  return {
969
1032
  isFullScreen: s,
970
- toggleFullScreen: async (c) => {
971
- s ? await w() : await h(c);
1033
+ toggleFullScreen: async (w) => {
1034
+ s ? await c() : await h(w);
972
1035
  },
973
1036
  enterFullScreen: h,
974
- exitFullScreen: w,
1037
+ exitFullScreen: c,
975
1038
  error: r
976
1039
  };
977
1040
  };
978
- function ct(t) {
1041
+ function bt(i) {
979
1042
  var r;
980
1043
  if (!navigator.onLine)
981
1044
  return {
@@ -984,57 +1047,57 @@ function ct(t) {
984
1047
  retryable: !0,
985
1048
  userMessage: "Please check your internet connection and try again."
986
1049
  };
987
- if (t.name === "AbortError" || (r = t.message) != null && r.includes("timeout"))
1050
+ if (i.name === "AbortError" || (r = i.message) != null && r.includes("timeout"))
988
1051
  return {
989
1052
  type: "timeout",
990
1053
  message: "Request timed out",
991
1054
  retryable: !0,
992
1055
  userMessage: "The request is taking longer than expected. Please try again."
993
1056
  };
994
- if (t.status) {
995
- const { status: i } = t;
996
- if (i === 401 || i === 403)
1057
+ if (i.status) {
1058
+ const { status: t } = i;
1059
+ if (t === 401 || t === 403)
997
1060
  return {
998
1061
  type: "auth",
999
- status: i,
1062
+ status: t,
1000
1063
  message: "Authentication failed",
1001
1064
  retryable: !1,
1002
1065
  userMessage: "Your session has expired. Please refresh the page."
1003
1066
  };
1004
- if (i === 429)
1067
+ if (t === 429)
1005
1068
  return {
1006
1069
  type: "rate-limit",
1007
- status: i,
1070
+ status: t,
1008
1071
  message: "Too many requests",
1009
1072
  retryable: !0,
1010
1073
  userMessage: "Please wait a moment before trying again."
1011
1074
  };
1012
- if (i >= 500)
1075
+ if (t >= 500)
1013
1076
  return {
1014
1077
  type: "server",
1015
- status: i,
1016
- message: `Server error: ${i}`,
1078
+ status: t,
1079
+ message: `Server error: ${t}`,
1017
1080
  retryable: !0,
1018
1081
  userMessage: "Our servers are experiencing issues. Please try again in a few moments."
1019
1082
  };
1020
- if (i >= 400)
1083
+ if (t >= 400)
1021
1084
  return {
1022
1085
  type: "client",
1023
- status: i,
1024
- message: `Client error: ${i}`,
1086
+ status: t,
1087
+ message: `Client error: ${t}`,
1025
1088
  retryable: !1,
1026
1089
  userMessage: "There was an issue with your request. Please check your input."
1027
1090
  };
1028
1091
  }
1029
1092
  return {
1030
1093
  type: "unknown",
1031
- message: t.message || "Unknown error occurred",
1094
+ message: i.message || "Unknown error occurred",
1032
1095
  retryable: !0,
1033
1096
  userMessage: "Something unexpected happened. Please try again.",
1034
- originalError: t
1097
+ originalError: i
1035
1098
  };
1036
1099
  }
1037
- async function he(t, r = {}, i = {
1100
+ async function xe(i, r = {}, t = {
1038
1101
  attempts: 3,
1039
1102
  backoff: "exponential",
1040
1103
  baseDelay: 1e3,
@@ -1042,9 +1105,9 @@ async function he(t, r = {}, i = {
1042
1105
  jitter: !0
1043
1106
  }) {
1044
1107
  let s;
1045
- for (let n = 1; n <= i.attempts; n++)
1108
+ for (let n = 1; n <= t.attempts; n++)
1046
1109
  try {
1047
- const o = new AbortController(), a = setTimeout(() => o.abort(), 6e4), l = await fetch(t, {
1110
+ const o = new AbortController(), a = setTimeout(() => o.abort(), 6e4), l = await fetch(i, {
1048
1111
  ...r,
1049
1112
  signal: o.signal
1050
1113
  });
@@ -1055,24 +1118,24 @@ async function he(t, r = {}, i = {
1055
1118
  return l;
1056
1119
  } catch (o) {
1057
1120
  s = o;
1058
- const a = ct(o);
1059
- if (!a.retryable || n === i.attempts)
1121
+ const a = bt(o);
1122
+ if (!a.retryable || n === t.attempts)
1060
1123
  throw a;
1061
- const l = dt(n, i);
1124
+ const l = yt(n, t);
1062
1125
  console.warn(
1063
- `API request failed (attempt ${n}/${i.attempts}), retrying in ${l}ms:`,
1126
+ `API request failed (attempt ${n}/${t.attempts}), retrying in ${l}ms:`,
1064
1127
  a.message
1065
1128
  ), await new Promise((d) => setTimeout(d, l));
1066
1129
  }
1067
1130
  throw s;
1068
1131
  }
1069
- function dt(t, r) {
1070
- let i;
1071
- return r.backoff === "exponential" ? i = r.baseDelay * Math.pow(2, t - 1) : i = r.baseDelay, i = Math.min(i, r.maxDelay), r.jitter && (i = i * (0.5 + Math.random() * 0.5)), Math.round(i);
1132
+ function yt(i, r) {
1133
+ let t;
1134
+ return r.backoff === "exponential" ? t = r.baseDelay * Math.pow(2, i - 1) : t = r.baseDelay, t = Math.min(t, r.maxDelay), r.jitter && (t = t * (0.5 + Math.random() * 0.5)), Math.round(t);
1072
1135
  }
1073
- class wt {
1136
+ class vt {
1074
1137
  constructor(r = {}) {
1075
- _(this, "config");
1138
+ F(this, "config");
1076
1139
  this.config = r;
1077
1140
  }
1078
1141
  /**
@@ -1085,11 +1148,11 @@ class wt {
1085
1148
  * Get default headers for API requests
1086
1149
  */
1087
1150
  getHeaders() {
1088
- var i;
1151
+ var t;
1089
1152
  const r = {
1090
1153
  "Content-Type": "application/json"
1091
1154
  };
1092
- return (i = this.config) != null && i.authToken && (r.Authorization = `Bearer ${this.config.authToken}`), r;
1155
+ return (t = this.config) != null && t.authToken && (r.Authorization = `Bearer ${this.config.authToken}`), r;
1093
1156
  }
1094
1157
  /**
1095
1158
  * Get base URL from config with fallback
@@ -1103,20 +1166,20 @@ class wt {
1103
1166
  */
1104
1167
  async generateQuestion({
1105
1168
  interviewId: r,
1106
- isInterviewDone: i = !1,
1169
+ isInterviewDone: t = !1,
1107
1170
  qnaId: s,
1108
1171
  question: n,
1109
1172
  answer: o,
1110
1173
  answerDuration: a
1111
1174
  }) {
1112
- const l = await he(
1175
+ const l = await xe(
1113
1176
  `${this.getBaseUrl()}/questions/next`,
1114
1177
  {
1115
1178
  method: "POST",
1116
1179
  headers: this.getHeaders(),
1117
1180
  body: JSON.stringify({
1118
1181
  interview_id: r,
1119
- is_interview_done: i,
1182
+ is_interview_done: t,
1120
1183
  qna_id: s,
1121
1184
  question: n,
1122
1185
  answer: o,
@@ -1130,31 +1193,31 @@ class wt {
1130
1193
  return await l.json();
1131
1194
  }
1132
1195
  }
1133
- function ut() {
1134
- const t = ae();
1196
+ function jt() {
1197
+ const i = ae();
1135
1198
  return X(() => {
1136
- const i = t.api || {};
1137
- return new wt(i);
1138
- }, [t.api]);
1199
+ const t = i.api || {};
1200
+ return new vt(t);
1201
+ }, [i.api]);
1139
1202
  }
1140
- const ht = (t) => {
1203
+ const Nt = (i) => {
1141
1204
  C(() => {
1142
1205
  const r = (s) => {
1143
- (s.ctrlKey || s.metaKey) && ["c", "v", "a", "t", "n", "w", "r", "s", "p"].includes(s.key.toLowerCase()) && (s.preventDefault(), t({
1206
+ (s.ctrlKey || s.metaKey) && ["c", "v", "a", "t", "n", "w", "r", "s", "p"].includes(s.key.toLowerCase()) && (s.preventDefault(), i({
1144
1207
  type: "blocked_shortcut",
1145
1208
  severity: "low",
1146
1209
  details: {
1147
1210
  action: "shortcut_pressed",
1148
1211
  reason: `Attempted to use a blocked keyboard shortcut: Ctrl + ${s.key}`
1149
1212
  }
1150
- })), s.key.startsWith("F") && s.key.length <= 3 && (s.preventDefault(), t({
1213
+ })), s.key.startsWith("F") && s.key.length <= 3 && (s.preventDefault(), i({
1151
1214
  type: "blocked_function_key",
1152
1215
  severity: "low",
1153
1216
  details: {
1154
1217
  action: "function_key_pressed",
1155
1218
  reason: `Attempted to use a blocked function key: ${s.key}`
1156
1219
  }
1157
- })), s.altKey && s.key === "Tab" && (s.preventDefault(), t({
1220
+ })), s.altKey && s.key === "Tab" && (s.preventDefault(), i({
1158
1221
  type: "alt_tab_attempt",
1159
1222
  severity: "medium",
1160
1223
  details: {
@@ -1162,8 +1225,8 @@ const ht = (t) => {
1162
1225
  reason: "Attempted to use the Alt + Tab shortcut"
1163
1226
  }
1164
1227
  }));
1165
- }, i = (s) => {
1166
- s.preventDefault(), t({
1228
+ }, t = (s) => {
1229
+ s.preventDefault(), i({
1167
1230
  type: "right_click_attempt",
1168
1231
  severity: "low",
1169
1232
  details: {
@@ -1172,23 +1235,23 @@ const ht = (t) => {
1172
1235
  }
1173
1236
  });
1174
1237
  };
1175
- return document.addEventListener("keydown", r), document.addEventListener("contextmenu", i), () => {
1176
- document.removeEventListener("keydown", r), document.removeEventListener("contextmenu", i);
1238
+ return document.addEventListener("keydown", r), document.addEventListener("contextmenu", t), () => {
1239
+ document.removeEventListener("keydown", r), document.removeEventListener("contextmenu", t);
1177
1240
  };
1178
- }, [t]);
1241
+ }, [i]);
1179
1242
  };
1180
1243
  class R extends Error {
1181
- constructor(r, i, s = !1) {
1182
- super(r), this.code = i, this.recoverable = s, this.name = "STTError";
1244
+ constructor(r, t, s = !1) {
1245
+ super(r), this.code = t, this.recoverable = s, this.name = "STTError";
1183
1246
  }
1184
1247
  }
1185
- class mt {
1248
+ class kt {
1186
1249
  constructor(r = {}) {
1187
- _(this, "config");
1188
- _(this, "mediaRecorder", null);
1189
- _(this, "audioChunks", []);
1190
- _(this, "recordingStream", null);
1191
- _(this, "autoStopTimeoutId", null);
1250
+ F(this, "config");
1251
+ F(this, "mediaRecorder", null);
1252
+ F(this, "audioChunks", []);
1253
+ F(this, "recordingStream", null);
1254
+ F(this, "autoStopTimeoutId", null);
1192
1255
  this.config = {
1193
1256
  baseUrl: "http://localhost:8000",
1194
1257
  provider: "groq",
@@ -1214,7 +1277,7 @@ class mt {
1214
1277
  /**
1215
1278
  * Start recording audio from user's microphone
1216
1279
  */
1217
- async startRecording(r, i) {
1280
+ async startRecording(r, t) {
1218
1281
  var s;
1219
1282
  if (!this.isRecordingSupported())
1220
1283
  throw new R(
@@ -1241,10 +1304,10 @@ class mt {
1241
1304
  mimeType: n
1242
1305
  }), this.mediaRecorder.ondataavailable = (o) => {
1243
1306
  var a;
1244
- o.data.size > 0 && (this.audioChunks.push(o.data), (a = i == null ? void 0 : i.onDataAvailable) == null || a.call(i, o.data));
1307
+ o.data.size > 0 && (this.audioChunks.push(o.data), (a = t == null ? void 0 : t.onDataAvailable) == null || a.call(t, o.data));
1245
1308
  }, this.mediaRecorder.onstop = () => {
1246
1309
  var o;
1247
- (o = i == null ? void 0 : i.onStop) == null || o.call(i);
1310
+ (o = t == null ? void 0 : t.onStop) == null || o.call(t);
1248
1311
  }, this.mediaRecorder.onerror = (o) => {
1249
1312
  var l;
1250
1313
  const a = new R(
@@ -1252,8 +1315,8 @@ class mt {
1252
1315
  "RECORDING_ERROR",
1253
1316
  !0
1254
1317
  );
1255
- (l = i == null ? void 0 : i.onError) == null || l.call(i, a), this.cleanup();
1256
- }, this.mediaRecorder.start(100), (s = i == null ? void 0 : i.onStart) == null || s.call(i), r && r > 0 && (this.autoStopTimeoutId = setTimeout(() => {
1318
+ (l = t == null ? void 0 : t.onError) == null || l.call(t, a), this.cleanup();
1319
+ }, this.mediaRecorder.start(100), (s = t == null ? void 0 : t.onStart) == null || s.call(t), r && r > 0 && (this.autoStopTimeoutId = setTimeout(() => {
1257
1320
  this.isRecording() && this.stopRecording();
1258
1321
  }, r * 1e3));
1259
1322
  } catch (n) {
@@ -1284,9 +1347,9 @@ class mt {
1284
1347
  "NO_ACTIVE_RECORDING",
1285
1348
  !1
1286
1349
  );
1287
- return new Promise((r, i) => {
1350
+ return new Promise((r, t) => {
1288
1351
  if (!this.mediaRecorder) {
1289
- i(
1352
+ t(
1290
1353
  new R("MediaRecorder is null", "MEDIARECORDER_NULL", !1)
1291
1354
  );
1292
1355
  return;
@@ -1296,7 +1359,7 @@ class mt {
1296
1359
  const o = s.mimeType || "audio/webm", a = new Blob(this.audioChunks, { type: o });
1297
1360
  this.cleanup(), r(a);
1298
1361
  } catch (o) {
1299
- i(
1362
+ t(
1300
1363
  new R(
1301
1364
  `Failed to create audio blob: ${o instanceof Error ? o.message : String(o)}`,
1302
1365
  "BLOB_CREATION_FAILED",
@@ -1313,24 +1376,24 @@ class mt {
1313
1376
  */
1314
1377
  async transcribe(r) {
1315
1378
  const {
1316
- audioBlob: i,
1379
+ audioBlob: t,
1317
1380
  model: s = this.config.model,
1318
1381
  language: n = this.config.language,
1319
1382
  includeTimestamps: o = this.config.includeTimestamps,
1320
1383
  temperature: a = this.config.temperature
1321
1384
  } = r;
1322
- if (!i || i.size === 0)
1385
+ if (!t || t.size === 0)
1323
1386
  throw new R(
1324
1387
  "Audio blob is empty or invalid",
1325
1388
  "INVALID_AUDIO",
1326
1389
  !1
1327
1390
  );
1328
1391
  try {
1329
- const l = new FormData(), d = new File([i], "recording.wav", {
1330
- type: i.type || "audio/wav"
1392
+ const l = new FormData(), d = new File([t], "recording.wav", {
1393
+ type: t.type || "audio/wav"
1331
1394
  });
1332
1395
  l.append("file", d), l.append("model", s || "whisper-large-v3-turbo"), l.append("language", n || "en"), l.append("include_timestamps", String(o || !1)), l.append("temperature", String(a || 0));
1333
- const w = await he(
1396
+ const c = await xe(
1334
1397
  `${this.config.baseUrl}/speech/transcribe`,
1335
1398
  {
1336
1399
  method: "POST",
@@ -1351,23 +1414,23 @@ class mt {
1351
1414
  jitter: !0
1352
1415
  }
1353
1416
  );
1354
- if (!w.ok) {
1355
- const h = await w.text();
1356
- let m = `STT request failed: ${w.status} ${w.statusText}`;
1417
+ if (!c.ok) {
1418
+ const h = await c.text();
1419
+ let m = `STT request failed: ${c.status} ${c.statusText}`;
1357
1420
  try {
1358
- const c = JSON.parse(h);
1359
- m = c.message || c.error || m;
1421
+ const w = JSON.parse(h);
1422
+ m = w.message || w.error || m;
1360
1423
  } catch {
1361
1424
  m = h || m;
1362
1425
  }
1363
1426
  throw new R(
1364
1427
  m,
1365
- `HTTP_${w.status}`,
1366
- w.status >= 500
1428
+ `HTTP_${c.status}`,
1429
+ c.status >= 500
1367
1430
  );
1368
1431
  }
1369
1432
  return {
1370
- transcript: (await w.json()).data.text ?? ""
1433
+ transcript: (await c.json()).data.text ?? ""
1371
1434
  };
1372
1435
  } catch (l) {
1373
1436
  throw l instanceof R ? l : new R(
@@ -1400,9 +1463,9 @@ class mt {
1400
1463
  "audio/mp4",
1401
1464
  "audio/wav"
1402
1465
  ];
1403
- for (const i of r)
1404
- if (MediaRecorder.isTypeSupported(i))
1405
- return i;
1466
+ for (const t of r)
1467
+ if (MediaRecorder.isTypeSupported(t))
1468
+ return t;
1406
1469
  return "audio/webm";
1407
1470
  }
1408
1471
  /**
@@ -1412,87 +1475,87 @@ class mt {
1412
1475
  this.recordingStream && (this.recordingStream.getTracks().forEach((r) => r.stop()), this.recordingStream = null), this.mediaRecorder = null, this.audioChunks = [], this.autoStopTimeoutId && (clearTimeout(this.autoStopTimeoutId), this.autoStopTimeoutId = null);
1413
1476
  }
1414
1477
  }
1415
- const J = new mt(), gt = (t = {}) => {
1416
- const [r, i] = k(!1), [s, n] = k(!1), [o, a] = k(null), [l, d] = k(null), [w, u] = k(null);
1417
- t.config && J.updateConfig(t.config);
1418
- const h = N(async (y) => {
1478
+ const J = new kt(), Et = (i = {}) => {
1479
+ const [r, t] = k(!1), [s, n] = k(!1), [o, a] = k(null), [l, d] = k(null), [c, u] = k(null);
1480
+ i.config && J.updateConfig(i.config);
1481
+ const h = N(async (v) => {
1419
1482
  var j;
1420
1483
  try {
1421
- d(null), a(null), u(null), await J.startRecording(y, {
1484
+ d(null), a(null), u(null), await J.startRecording(v, {
1422
1485
  onStart: () => {
1423
- var f;
1424
- i(!0), (f = t.onStart) == null || f.call(t);
1486
+ var x;
1487
+ t(!0), (x = i.onStart) == null || x.call(i);
1425
1488
  },
1426
1489
  onStop: () => {
1427
- var f;
1428
- i(!1), (f = t.onStop) == null || f.call(t);
1490
+ var x;
1491
+ t(!1), (x = i.onStop) == null || x.call(i);
1429
1492
  },
1430
- onError: (f) => {
1493
+ onError: (x) => {
1431
1494
  var S;
1432
- const E = f instanceof R ? f : new R(f.message, "RECORDING_ERROR", !0);
1433
- d(E), i(!1), (S = t.onError) == null || S.call(t, E);
1495
+ const E = x instanceof R ? x : new R(x.message, "RECORDING_ERROR", !0);
1496
+ d(E), t(!1), (S = i.onError) == null || S.call(i, E);
1434
1497
  }
1435
1498
  });
1436
- } catch (f) {
1437
- const E = f instanceof R ? f : new R(
1438
- f instanceof Error ? f.message : String(f),
1499
+ } catch (x) {
1500
+ const E = x instanceof R ? x : new R(
1501
+ x instanceof Error ? x.message : String(x),
1439
1502
  "START_FAILED",
1440
1503
  !1
1441
1504
  );
1442
- throw d(E), i(!1), (j = t.onError) == null || j.call(t, E), E;
1505
+ throw d(E), t(!1), (j = i.onError) == null || j.call(i, E), E;
1443
1506
  }
1444
1507
  }, []), m = N(async () => {
1445
- var y, j;
1508
+ var v, j;
1446
1509
  try {
1447
- const f = await J.stopRecording();
1448
- return u(f), i(!1), (y = t.onStop) == null || y.call(t), f;
1449
- } catch (f) {
1450
- const E = f instanceof R ? f : new R(
1451
- f instanceof Error ? f.message : String(f),
1510
+ const x = await J.stopRecording();
1511
+ return u(x), t(!1), (v = i.onStop) == null || v.call(i), x;
1512
+ } catch (x) {
1513
+ const E = x instanceof R ? x : new R(
1514
+ x instanceof Error ? x.message : String(x),
1452
1515
  "STOP_FAILED",
1453
1516
  !1
1454
1517
  );
1455
- throw d(E), i(!1), (j = t.onError) == null || j.call(t, E), E;
1518
+ throw d(E), t(!1), (j = i.onError) == null || j.call(i, E), E;
1456
1519
  }
1457
- }, []), c = N(
1458
- async (y, j = {}) => {
1459
- var f, E;
1520
+ }, []), w = N(
1521
+ async (v, j = {}) => {
1522
+ var x, E;
1460
1523
  try {
1461
1524
  d(null), n(!0);
1462
1525
  const S = {
1463
- audioBlob: y,
1526
+ audioBlob: v,
1464
1527
  ...j
1465
- }, v = await J.transcribe(S);
1466
- return a(v.transcript), n(!1), (f = t.onTranscriptionComplete) == null || f.call(t, v), v;
1528
+ }, y = await J.transcribe(S);
1529
+ return a(y.transcript), n(!1), (x = i.onTranscriptionComplete) == null || x.call(i, y), y;
1467
1530
  } catch (S) {
1468
- const v = S instanceof R ? S : new R(
1531
+ const y = S instanceof R ? S : new R(
1469
1532
  S instanceof Error ? S.message : String(S),
1470
1533
  "TRANSCRIPTION_FAILED",
1471
1534
  !0
1472
1535
  );
1473
- throw d(v), n(!1), (E = t.onError) == null || E.call(t, v), v;
1536
+ throw d(y), n(!1), (E = i.onError) == null || E.call(i, y), y;
1474
1537
  }
1475
1538
  },
1476
1539
  []
1477
- ), x = N(() => {
1478
- J.cancelRecording(), i(!1), u(null);
1540
+ ), f = N(() => {
1541
+ J.cancelRecording(), t(!1), u(null);
1479
1542
  }, []);
1480
1543
  return {
1481
1544
  startRecording: h,
1482
1545
  stopRecording: m,
1483
- transcribe: c,
1484
- cancelRecording: x,
1546
+ transcribe: w,
1547
+ cancelRecording: f,
1485
1548
  isRecording: r,
1486
1549
  isTranscribing: s,
1487
1550
  transcript: o,
1488
1551
  error: l,
1489
- audioBlob: w
1552
+ audioBlob: c
1490
1553
  };
1491
- }, xt = (t) => {
1492
- const r = T(null), i = T(!1);
1554
+ }, Tt = (i) => {
1555
+ const r = T(null), t = T(!1);
1493
1556
  C(() => {
1494
1557
  const s = () => {
1495
- document.hidden && (i.current = !0, r.current && (clearTimeout(r.current), r.current = null), t({
1558
+ document.hidden && (t.current = !0, r.current && (clearTimeout(r.current), r.current = null), i({
1496
1559
  type: "tab_switch",
1497
1560
  severity: "high",
1498
1561
  details: {
@@ -1500,11 +1563,11 @@ const J = new mt(), gt = (t = {}) => {
1500
1563
  reason: "Attempted to switch tabs or applications"
1501
1564
  }
1502
1565
  }), setTimeout(() => {
1503
- i.current = !1;
1566
+ t.current = !1;
1504
1567
  }, 100));
1505
1568
  }, n = () => {
1506
- i.current || (r.current = setTimeout(() => {
1507
- i.current || t({
1569
+ t.current || (r.current = setTimeout(() => {
1570
+ t.current || i({
1508
1571
  type: "focus_loss",
1509
1572
  severity: "medium",
1510
1573
  details: {
@@ -1517,11 +1580,11 @@ const J = new mt(), gt = (t = {}) => {
1517
1580
  return document.addEventListener("visibilitychange", s), window.addEventListener("blur", n), () => {
1518
1581
  document.removeEventListener("visibilitychange", s), window.removeEventListener("blur", n), r.current && clearTimeout(r.current);
1519
1582
  };
1520
- }, [t]);
1521
- }, ft = () => {
1583
+ }, [i]);
1584
+ }, Ct = () => {
1522
1585
  C(() => {
1523
- const t = document.createElement("style");
1524
- return t.textContent = `
1586
+ const i = document.createElement("style");
1587
+ return i.textContent = `
1525
1588
  * {
1526
1589
  -webkit-user-select: none !important;
1527
1590
  -moz-user-select: none !important;
@@ -1534,15 +1597,15 @@ const J = new mt(), gt = (t = {}) => {
1534
1597
  -ms-user-select: text !important;
1535
1598
  user-select: text !important;
1536
1599
  }
1537
- `, document.head.appendChild(t), () => {
1538
- document.head.removeChild(t);
1600
+ `, document.head.appendChild(i), () => {
1601
+ document.head.removeChild(i);
1539
1602
  };
1540
1603
  }, []);
1541
1604
  };
1542
- class pt {
1605
+ class St {
1543
1606
  constructor(r = {}) {
1544
- _(this, "config");
1545
- _(this, "currentAudio", null);
1607
+ F(this, "config");
1608
+ F(this, "currentAudio", null);
1546
1609
  this.config = {
1547
1610
  baseUrl: "http://localhost:8000",
1548
1611
  provider: "piper",
@@ -1562,12 +1625,12 @@ class pt {
1562
1625
  */
1563
1626
  async synthesizeSpeech(r) {
1564
1627
  const {
1565
- text: i,
1628
+ text: t,
1566
1629
  voice: s = this.config.voice,
1567
1630
  speed: n = this.config.speed
1568
1631
  } = r, o = new URLSearchParams();
1569
- o.append("text", i), o.append("voice", s || "string"), o.append("speed", (n == null ? void 0 : n.toString()) || "1");
1570
- const a = await he(
1632
+ o.append("text", t), o.append("voice", s || "string"), o.append("speed", (n == null ? void 0 : n.toString()) || "1");
1633
+ const a = await xe(
1571
1634
  `${this.config.baseUrl}/speech/synthesize`,
1572
1635
  {
1573
1636
  method: "POST",
@@ -1606,35 +1669,35 @@ class pt {
1606
1669
  /**
1607
1670
  * Speak text and return a promise that resolves when playback completes
1608
1671
  */
1609
- async speak(r, i) {
1672
+ async speak(r, t) {
1610
1673
  var s, n;
1611
1674
  try {
1612
- this.stop(), (s = i == null ? void 0 : i.onStart) == null || s.call(i);
1675
+ this.stop(), (s = t == null ? void 0 : t.onStart) == null || s.call(t);
1613
1676
  const o = await this.synthesizeSpeech(r), a = URL.createObjectURL(o);
1614
1677
  return this.currentAudio = new Audio(a), new Promise((l, d) => {
1615
1678
  if (!this.currentAudio) {
1616
1679
  d(new Error("Audio element not created"));
1617
1680
  return;
1618
1681
  }
1619
- const w = this.currentAudio;
1620
- w.onended = () => {
1682
+ const c = this.currentAudio;
1683
+ c.onended = () => {
1621
1684
  var u;
1622
- URL.revokeObjectURL(a), this.currentAudio = null, (u = i == null ? void 0 : i.onEnd) == null || u.call(i), l();
1623
- }, w.onerror = (u) => {
1685
+ URL.revokeObjectURL(a), this.currentAudio = null, (u = t == null ? void 0 : t.onEnd) == null || u.call(t), l();
1686
+ }, c.onerror = (u) => {
1624
1687
  var m;
1625
1688
  URL.revokeObjectURL(a), this.currentAudio = null;
1626
1689
  const h = new Error(`Audio playback failed: ${u}`);
1627
- (m = i == null ? void 0 : i.onError) == null || m.call(i, h), d(h);
1628
- }, w.play().catch((u) => {
1690
+ (m = t == null ? void 0 : t.onError) == null || m.call(t, h), d(h);
1691
+ }, c.play().catch((u) => {
1629
1692
  var m;
1630
1693
  URL.revokeObjectURL(a), this.currentAudio = null;
1631
1694
  const h = new Error(`Failed to play audio: ${u.message}`);
1632
- (m = i == null ? void 0 : i.onError) == null || m.call(i, h), d(h);
1695
+ (m = t == null ? void 0 : t.onError) == null || m.call(t, h), d(h);
1633
1696
  });
1634
1697
  });
1635
1698
  } catch (o) {
1636
1699
  const a = o instanceof Error ? o : new Error(`TTS Error: ${String(o)}`);
1637
- throw (n = i == null ? void 0 : i.onError) == null || n.call(i, a), a;
1700
+ throw (n = t == null ? void 0 : t.onError) == null || n.call(t, a), a;
1638
1701
  }
1639
1702
  }
1640
1703
  /**
@@ -1650,40 +1713,40 @@ class pt {
1650
1713
  return this.currentAudio !== null && !this.currentAudio.paused;
1651
1714
  }
1652
1715
  }
1653
- const we = new pt(), bt = (t = {}) => {
1654
- const [r, i] = k(!1), [s, n] = k(!1), [o, a] = k(null);
1655
- t.config && we.updateConfig(t.config);
1716
+ const we = new St(), It = (i = {}) => {
1717
+ const [r, t] = k(!1), [s, n] = k(!1), [o, a] = k(null);
1718
+ i.config && we.updateConfig(i.config);
1656
1719
  const l = N(
1657
- async (w, u = {}) => {
1720
+ async (c, u = {}) => {
1658
1721
  var h;
1659
1722
  try {
1660
1723
  a(null), n(!0);
1661
1724
  const m = {
1662
- text: w,
1725
+ text: c,
1663
1726
  ...u
1664
1727
  };
1665
1728
  await we.speak(m, {
1666
1729
  onStart: () => {
1667
- var c;
1668
- n(!1), i(!0), (c = t.onStart) == null || c.call(t);
1730
+ var w;
1731
+ n(!1), t(!0), (w = i.onStart) == null || w.call(i);
1669
1732
  },
1670
1733
  onEnd: () => {
1671
- var c;
1672
- i(!1), (c = t.onEnd) == null || c.call(t);
1734
+ var w;
1735
+ t(!1), (w = i.onEnd) == null || w.call(i);
1673
1736
  },
1674
- onError: (c) => {
1675
- var x;
1676
- i(!1), n(!1), a(c), (x = t.onError) == null || x.call(t, c);
1737
+ onError: (w) => {
1738
+ var f;
1739
+ t(!1), n(!1), a(w), (f = i.onError) == null || f.call(i, w);
1677
1740
  }
1678
1741
  });
1679
1742
  } catch (m) {
1680
- const c = m instanceof Error ? m : new Error(String(m));
1681
- throw a(c), i(!1), n(!1), (h = t.onError) == null || h.call(t, c), c;
1743
+ const w = m instanceof Error ? m : new Error(String(m));
1744
+ throw a(w), t(!1), n(!1), (h = i.onError) == null || h.call(i, w), w;
1682
1745
  }
1683
1746
  },
1684
- [t]
1747
+ [i]
1685
1748
  ), d = N(() => {
1686
- we.stop(), i(!1), n(!1);
1749
+ we.stop(), t(!1), n(!1);
1687
1750
  }, []);
1688
1751
  return {
1689
1752
  speak: l,
@@ -1692,44 +1755,44 @@ const we = new pt(), bt = (t = {}) => {
1692
1755
  isLoading: s,
1693
1756
  error: o
1694
1757
  };
1695
- }, vt = ({
1696
- onViolation: t,
1758
+ }, Rt = ({
1759
+ onViolation: i,
1697
1760
  onEnd: r,
1698
- maxViolations: i = 5
1761
+ maxViolations: t = 5
1699
1762
  }) => {
1700
- const { addViolation: s } = We(), n = Be(), o = Ge(), a = T(o);
1763
+ const { addViolation: s } = tt(), n = Ze(), o = et(), a = T(o);
1701
1764
  C(() => {
1702
1765
  a.current = o;
1703
1766
  }, [o]);
1704
1767
  const l = N(
1705
- (w) => {
1706
- r && r(w, a.current);
1768
+ (c) => {
1769
+ r && r(c, a.current);
1707
1770
  },
1708
1771
  [r]
1709
1772
  );
1710
1773
  return {
1711
1774
  logViolation: N(
1712
- ({ type: w, severity: u, details: h }) => {
1775
+ ({ type: c, severity: u, details: h }) => {
1713
1776
  const m = {
1714
- id: Xe(),
1715
- type: w,
1777
+ id: lt(),
1778
+ type: c,
1716
1779
  severity: u,
1717
1780
  details: h,
1718
1781
  timestamp: Date.now()
1719
1782
  };
1720
1783
  s(m);
1721
- const c = a.current + 1;
1722
- t && t(m, c), c >= i && l("excessive_violations");
1784
+ const w = a.current + 1;
1785
+ i && i(m, w), w >= t && l("excessive_violations");
1723
1786
  },
1724
- [s, t, i, l]
1787
+ [s, i, t, l]
1725
1788
  ),
1726
1789
  onInterviewEnd: l,
1727
1790
  violationCount: o,
1728
1791
  logList: n
1729
1792
  };
1730
- }, yt = () => {
1793
+ }, At = () => {
1731
1794
  C(() => {
1732
- function t() {
1795
+ function i() {
1733
1796
  console.clear(), console.log(
1734
1797
  `
1735
1798
  %c
@@ -1765,11 +1828,11 @@ const we = new pt(), bt = (t = {}) => {
1765
1828
  ), console.log(
1766
1829
  `
1767
1830
  %c
1768
- ◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆
1831
+ ◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆
1769
1832
  ◇ ◇
1770
1833
  ◆ 🔒 INTERVIEW INTEGRITY SYSTEM ACTIVATED 🔒 ◆
1771
1834
  ◇ ◇
1772
- ◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆
1835
+ ◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆◇◆
1773
1836
 
1774
1837
  `,
1775
1838
  "color: #4ecdc4; font-size: 16px; font-weight: bold; text-shadow: 0 0 10px #4ecdc4;"
@@ -1790,8 +1853,8 @@ const we = new pt(), bt = (t = {}) => {
1790
1853
  "color: #ffd93d; font-size: 14px; font-family: monospace; background: rgba(255, 217, 61, 0.1); padding: 10px;"
1791
1854
  );
1792
1855
  }
1793
- const r = { open: !1, orientation: null }, i = 160, s = setInterval(() => {
1794
- window.outerHeight - window.innerHeight > i || window.outerWidth - window.innerWidth > i ? r.open || (r.open = !0, r.orientation = window.outerWidth - window.innerWidth > i ? "vertical" : "horizontal", t()) : r.open && (r.open = !1, console.log(
1856
+ const r = { open: !1, orientation: null }, t = 160, s = setInterval(() => {
1857
+ window.outerHeight - window.innerHeight > t || window.outerWidth - window.innerWidth > t ? r.open || (r.open = !0, r.orientation = window.outerWidth - window.innerWidth > t ? "vertical" : "horizontal", i()) : r.open && (r.open = !1, console.log(
1795
1858
  "%c🌟 Developer tools closed. Interview continues smoothly! ✨",
1796
1859
  "color: #4ecdc4; font-weight: bold; text-shadow: 0 0 10px #4ecdc4;"
1797
1860
  ));
@@ -1809,7 +1872,7 @@ const we = new pt(), bt = (t = {}) => {
1809
1872
  clearInterval(s), document.removeEventListener("keydown", n), document.removeEventListener("contextmenu", o), delete window.showStats, delete window.interviewTips;
1810
1873
  };
1811
1874
  }, []);
1812
- }, me = (t) => /* @__PURE__ */ e.jsxs(
1875
+ }, pe = (i) => /* @__PURE__ */ e.jsxs(
1813
1876
  "svg",
1814
1877
  {
1815
1878
  xmlns: "http://www.w3.org/2000/svg",
@@ -1821,7 +1884,7 @@ const we = new pt(), bt = (t = {}) => {
1821
1884
  strokeWidth: "2",
1822
1885
  strokeLinecap: "round",
1823
1886
  strokeLinejoin: "round",
1824
- ...t,
1887
+ ...i,
1825
1888
  children: [
1826
1889
  /* @__PURE__ */ e.jsx("path", { d: "M12 2a10 10 0 0 1 7.38 16.75" }),
1827
1890
  /* @__PURE__ */ e.jsx("path", { d: "M12 6v6l4 2" }),
@@ -1831,36 +1894,36 @@ const we = new pt(), bt = (t = {}) => {
1831
1894
  /* @__PURE__ */ e.jsx("path", { d: "M8.644 21.42a10 10 0 0 0 7.631-.38" })
1832
1895
  ]
1833
1896
  }
1834
- ), jt = (t, r, i) => Math.max(r, Math.min(i, t)), be = (t) => {
1835
- const r = Math.max(0, Math.floor(t)), i = Math.floor(r / 60).toString().padStart(2, "0"), s = (r % 60).toString().padStart(2, "0");
1836
- return `${i}:${s}`;
1837
- }, ge = ({
1838
- total: t,
1897
+ ), Mt = (i, r, t) => Math.max(r, Math.min(t, i)), je = (i) => {
1898
+ const r = Math.max(0, Math.floor(i)), t = Math.floor(r / 60).toString().padStart(2, "0"), s = (r % 60).toString().padStart(2, "0");
1899
+ return `${t}:${s}`;
1900
+ }, be = ({
1901
+ total: i,
1839
1902
  remaining: r,
1840
- size: i = 64,
1903
+ size: t = 64,
1841
1904
  strokeWidth: s = 6,
1842
1905
  className: n = "",
1843
1906
  showLabel: o = !0
1844
1907
  }) => {
1845
- const a = Math.max(1, t || 1), l = jt(r / a, 0, 1), { radius: d, circumference: w, dashOffset: u, center: h } = X(() => {
1846
- const x = (i - s) / 2, y = 2 * Math.PI * x, j = y * (1 - l), f = Math.round(s) % 2 === 1, E = i / 2 + (f ? 0.5 : 0);
1847
- return { radius: x, circumference: y, dashOffset: j, center: E };
1848
- }, [i, s, l]), m = X(() => l <= 0.25 ? "iw-stroke-red-500" : l <= 0.5 ? "iw-stroke-yellow-500" : "iw-stroke-green-500", [l]), c = l <= 0.25 ? "iw-animate-pulse" : "";
1908
+ const a = Math.max(1, i || 1), l = Mt(r / a, 0, 1), { radius: d, circumference: c, dashOffset: u, center: h } = X(() => {
1909
+ const f = (t - s) / 2, v = 2 * Math.PI * f, j = v * (1 - l), x = Math.round(s) % 2 === 1, E = t / 2 + (x ? 0.5 : 0);
1910
+ return { radius: f, circumference: v, dashOffset: j, center: E };
1911
+ }, [t, s, l]), m = X(() => l <= 0.25 ? "iw-stroke-red-500" : l <= 0.5 ? "iw-stroke-yellow-500" : "iw-stroke-green-500", [l]), w = l <= 0.25 ? "iw-animate-pulse" : "";
1849
1912
  return /* @__PURE__ */ e.jsxs(
1850
1913
  "div",
1851
1914
  {
1852
1915
  className: `iw-relative iw-inline-flex iw-items-center iw-justify-center iw-rounded-full iw-bg-white ${n}`,
1853
- style: { width: i, height: i },
1854
- "aria-label": `Time remaining ${be(r)}`,
1916
+ style: { width: t, height: t },
1917
+ "aria-label": `Time remaining ${je(r)}`,
1855
1918
  role: "timer",
1856
1919
  "aria-live": "polite",
1857
1920
  children: [
1858
1921
  /* @__PURE__ */ e.jsx(
1859
1922
  "svg",
1860
1923
  {
1861
- width: i,
1862
- height: i,
1863
- viewBox: `0 0 ${i} ${i}`,
1924
+ width: t,
1925
+ height: t,
1926
+ viewBox: `0 0 ${t} ${t}`,
1864
1927
  preserveAspectRatio: "xMidYMid meet",
1865
1928
  children: /* @__PURE__ */ e.jsxs("g", { transform: `rotate(-90 ${h} ${h})`, children: [
1866
1929
  /* @__PURE__ */ e.jsx(
@@ -1882,11 +1945,11 @@ const we = new pt(), bt = (t = {}) => {
1882
1945
  cx: h,
1883
1946
  cy: h,
1884
1947
  r: d,
1885
- className: `${m} ${c}`,
1948
+ className: `${m} ${w}`,
1886
1949
  strokeWidth: s,
1887
1950
  strokeLinecap: "round",
1888
1951
  fill: "none",
1889
- strokeDasharray: w,
1952
+ strokeDasharray: c,
1890
1953
  strokeDashoffset: u,
1891
1954
  shapeRendering: "geometricPrecision",
1892
1955
  vectorEffect: "non-scaling-stroke",
@@ -1902,39 +1965,39 @@ const we = new pt(), bt = (t = {}) => {
1902
1965
  "span",
1903
1966
  {
1904
1967
  className: `iw-text-[11px] iw-font-semibold iw-tabular-nums ${l <= 0.25 ? "iw-text-red-600" : l <= 0.5 ? "iw-text-yellow-600" : "iw-text-green-600"}`,
1905
- children: be(r)
1968
+ children: je(r)
1906
1969
  }
1907
1970
  ) })
1908
1971
  ]
1909
1972
  }
1910
1973
  );
1911
- }, Nt = ({
1912
- label: t,
1974
+ }, Dt = ({
1975
+ label: i,
1913
1976
  error: r,
1914
- fullWidth: i = !1,
1977
+ fullWidth: t = !1,
1915
1978
  className: s = "",
1916
1979
  id: n,
1917
1980
  ...o
1918
1981
  }) => {
1919
- const a = n || `textarea-${Math.random().toString(36).substring(2, 9)}`, l = "iw-block iw-rounded-md iw-border iw-border-gray-300 iw-shadow-sm iw-px-4 iw-py-2 iw-text-sm iw-transition-all", d = r ? "iw-border-red-500 iw-focus:border-red-500 iw-focus:ring-red-500" : "", w = i ? "iw-w-full" : "", u = s.includes("iw-h-full") || i ? "iw-h-full" : "";
1982
+ const a = n || `textarea-${Math.random().toString(36).substring(2, 9)}`, l = "iw-block iw-rounded-md iw-border iw-border-gray-300 iw-shadow-sm iw-px-4 iw-py-2 iw-text-sm iw-transition-all", d = r ? "iw-border-red-500 iw-focus:border-red-500 iw-focus:ring-red-500" : "", c = t ? "iw-w-full" : "", u = s.includes("iw-h-full") || t ? "iw-h-full" : "";
1920
1983
  return /* @__PURE__ */ e.jsxs(
1921
1984
  "div",
1922
1985
  {
1923
- className: `iw-h-full iw-flex iw-flex-col ${i ? "iw-w-full" : ""}`,
1986
+ className: `iw-h-full iw-flex iw-flex-col ${t ? "iw-w-full" : ""}`,
1924
1987
  children: [
1925
- t && /* @__PURE__ */ e.jsx(
1988
+ i && /* @__PURE__ */ e.jsx(
1926
1989
  "label",
1927
1990
  {
1928
1991
  htmlFor: a,
1929
1992
  className: "iw-block iw-text-sm iw-font-medium iw-text-gray-700 iw-mb-1",
1930
- children: t
1993
+ children: i
1931
1994
  }
1932
1995
  ),
1933
1996
  /* @__PURE__ */ e.jsx(
1934
1997
  "textarea",
1935
1998
  {
1936
1999
  id: a,
1937
- className: `${l} ${d} ${w} ${u} ${s}`,
2000
+ className: `${l} ${d} ${c} ${u} ${s}`,
1938
2001
  "aria-invalid": r ? "true" : "false",
1939
2002
  ...o
1940
2003
  }
@@ -1943,27 +2006,27 @@ const we = new pt(), bt = (t = {}) => {
1943
2006
  ]
1944
2007
  }
1945
2008
  );
1946
- }, kt = ({
1947
- value: t,
2009
+ }, _t = ({
2010
+ value: i,
1948
2011
  onChange: r,
1949
- onSubmit: i,
2012
+ onSubmit: t,
1950
2013
  isSubmitDisabled: s,
1951
2014
  state: n,
1952
2015
  editingTime: o
1953
2016
  }) => {
1954
2017
  const a = (l) => {
1955
- l.key === "Enter" && (l.ctrlKey || l.metaKey) && !s && (l.preventDefault(), i());
2018
+ l.key === "Enter" && (l.ctrlKey || l.metaKey) && !s && (l.preventDefault(), t());
1956
2019
  };
1957
2020
  return /* @__PURE__ */ e.jsxs("div", { className: "iw-flex iw-flex-col iw-h-full ", children: [
1958
2021
  /* @__PURE__ */ e.jsxs("div", { className: "iw-flex iw-items-center iw-justify-between", children: [
1959
2022
  /* @__PURE__ */ e.jsx("h3", { className: "iw-text-lg iw-font-semibold iw-text-gray-900 iw-mb-1", children: "Your Answer" }),
1960
2023
  /* @__PURE__ */ e.jsxs("div", { className: "iw-flex iw-items-center iw-justify-center iw-gap-2", children: [
1961
2024
  /* @__PURE__ */ e.jsxs("div", { className: "iw-flex iw-items-center iw-gap-1", children: [
1962
- /* @__PURE__ */ e.jsx(me, { className: "iw-size-4 iw-text-orange-600" }),
2025
+ /* @__PURE__ */ e.jsx(pe, { className: "iw-size-4 iw-text-orange-600" }),
1963
2026
  /* @__PURE__ */ e.jsx("p", { className: "iw-text-gray-700 iw-text-sm", children: "Time to edit: " })
1964
2027
  ] }),
1965
2028
  /* @__PURE__ */ e.jsx(
1966
- ge,
2029
+ be,
1967
2030
  {
1968
2031
  total: o,
1969
2032
  remaining: n.currentPhaseTimeRemaining,
@@ -1975,9 +2038,9 @@ const we = new pt(), bt = (t = {}) => {
1975
2038
  ] }),
1976
2039
  /* @__PURE__ */ e.jsxs("div", { className: " iw-overflow-hidden iw-flex iw-flex-col iw-h-full iw-mt-2", children: [
1977
2040
  /* @__PURE__ */ e.jsx(
1978
- Nt,
2041
+ Dt,
1979
2042
  {
1980
- value: t,
2043
+ value: i,
1981
2044
  onChange: r,
1982
2045
  onKeyDown: a,
1983
2046
  placeholder: "Type your answer here...",
@@ -1989,12 +2052,12 @@ const we = new pt(), bt = (t = {}) => {
1989
2052
  onDragOver: (l) => l.preventDefault()
1990
2053
  }
1991
2054
  ),
1992
- /* @__PURE__ */ e.jsx("div", { className: "iw-w-full iw-grid iw-grid-cols-1 iw-mt-4", children: /* @__PURE__ */ e.jsx(W, { onClick: i, disabled: s, children: "Submit Answer" }) })
2055
+ /* @__PURE__ */ e.jsx("div", { className: "iw-w-full iw-grid iw-grid-cols-1 iw-mt-4", children: /* @__PURE__ */ e.jsx(V, { onClick: t, disabled: s, children: "Submit Answer" }) })
1993
2056
  ] })
1994
2057
  ] });
1995
- }, Et = ({ className: t = "" }) => {
2058
+ }, Pt = ({ className: i = "" }) => {
1996
2059
  var n;
1997
- const { authToken: r } = Se(), i = r ? Ze(r) : null, s = T(null);
2060
+ const { authToken: r } = Me(), t = r ? ct(r) : null, s = T(null);
1998
2061
  return C(() => {
1999
2062
  let o = null;
2000
2063
  return (async () => {
@@ -2009,7 +2072,7 @@ const we = new pt(), bt = (t = {}) => {
2009
2072
  })(), () => {
2010
2073
  o && o.getTracks().forEach((l) => l.stop());
2011
2074
  };
2012
- }, []), /* @__PURE__ */ e.jsxs("div", { className: `iw-relative ${t}`, children: [
2075
+ }, []), /* @__PURE__ */ e.jsxs("div", { className: `iw-relative ${i}`, children: [
2013
2076
  /* @__PURE__ */ e.jsx(
2014
2077
  "video",
2015
2078
  {
@@ -2027,18 +2090,18 @@ const we = new pt(), bt = (t = {}) => {
2027
2090
  /* @__PURE__ */ e.jsx("div", { className: "iw-size-2 iw-animate-pulse iw-rounded-full iw-bg-red-500" }),
2028
2091
  /* @__PURE__ */ e.jsx("span", { className: "iw-font-medium iw-text-white", children: "Recording" })
2029
2092
  ] }),
2030
- ((n = i == null ? void 0 : i.data) == null ? void 0 : n.user_name) && /* @__PURE__ */ e.jsx("div", { className: "iw-absolute iw-bottom-4 iw-right-4 iw-inline-flex iw-items-center iw-gap-2 iw-rounded-lg iw-border iw-border-white/10 iw-bg-black/40 iw-px-4 iw-py-2 iw-backdrop-blur-md", children: /* @__PURE__ */ e.jsx("span", { className: "iw-font-medium iw-text-white", children: i.data.user_name }) })
2093
+ ((n = t == null ? void 0 : t.data) == null ? void 0 : n.user_name) && /* @__PURE__ */ e.jsx("div", { className: "iw-absolute iw-bottom-4 iw-right-4 iw-inline-flex iw-items-center iw-gap-2 iw-rounded-lg iw-border iw-border-white/10 iw-bg-black/40 iw-px-4 iw-py-2 iw-backdrop-blur-md", children: /* @__PURE__ */ e.jsx("span", { className: "iw-font-medium iw-text-white", children: t.data.user_name }) })
2031
2094
  ] });
2032
- }, Tt = ({
2033
- question: t,
2095
+ }, Ft = ({
2096
+ question: i,
2034
2097
  isLoading: r = !1
2035
2098
  }) => {
2036
- const { baseColor: i } = Z();
2099
+ const { baseColor: t } = Z();
2037
2100
  return /* @__PURE__ */ e.jsx(
2038
2101
  "div",
2039
2102
  {
2040
2103
  className: "iw-rounded-xl iw-mb-4 message-animation iw-text-gray-800 iw-p-6 ",
2041
- style: Ke(i, 0.85),
2104
+ style: at(t, 0.85),
2042
2105
  children: /* @__PURE__ */ e.jsxs("div", { className: "iw-flex iw-items-center iw-gap-8", children: [
2043
2106
  /* @__PURE__ */ e.jsx("div", { className: "iw-flex iw-flex-col iw-items-center iw-relative iw-h-32 iw-w-32 iw-shrink-0 iw-shadow iw-rounded-lg iw-bg-white", children: /* @__PURE__ */ e.jsx("div", { className: "iw-mt-2", children: /* @__PURE__ */ e.jsx(
2044
2107
  "img",
@@ -2051,37 +2114,37 @@ const we = new pt(), bt = (t = {}) => {
2051
2114
  r ? /* @__PURE__ */ e.jsxs("div", { className: "iw-animate-pulse iw-w-full iw-space-y-3 iw-mr-10", children: [
2052
2115
  /* @__PURE__ */ e.jsx("div", { className: "iw-h-5 iw-bg-gray-200 iw-rounded iw-w-full" }),
2053
2116
  /* @__PURE__ */ e.jsx("div", { className: "iw-h-5 iw-bg-gray-200 iw-rounded iw-w-3/4" })
2054
- ] }) : /* @__PURE__ */ e.jsx("p", { className: "iw-text-lg iw-leading-8", children: t == null ? void 0 : t.question })
2117
+ ] }) : /* @__PURE__ */ e.jsx("p", { className: "iw-text-lg iw-leading-8", children: i == null ? void 0 : i.question })
2055
2118
  ] })
2056
2119
  }
2057
2120
  );
2058
- }, ve = ({
2059
- currentQuestion: t,
2121
+ }, Ne = ({
2122
+ currentQuestion: i,
2060
2123
  phase: r,
2061
- className: i = "",
2124
+ className: t = "",
2062
2125
  children: s
2063
2126
  }) => /* @__PURE__ */ e.jsxs(
2064
2127
  "div",
2065
2128
  {
2066
- className: `iw-p-4 iw-space-y-4 iw-pb-6 ${i} iw-min-h-[calc(100vh_-_3.8rem)] iw-flex iw-flex-col iw-justify-between`,
2129
+ className: `iw-p-4 iw-space-y-4 iw-pb-6 ${t} iw-min-h-[calc(100vh_-_3.8rem)] iw-flex iw-flex-col iw-justify-between`,
2067
2130
  children: [
2068
2131
  /* @__PURE__ */ e.jsx("div", { className: "iw-flex iw-items-start iw-justify-between iw-gap-3", children: /* @__PURE__ */ e.jsx("div", { className: "iw-flex-1", children: /* @__PURE__ */ e.jsx(
2069
- Tt,
2132
+ Ft,
2070
2133
  {
2071
- question: t,
2072
- isLoading: r === P.FETCHING_QUESTION || r === P.IDLE
2134
+ question: i,
2135
+ isLoading: r === _.FETCHING_QUESTION || r === _.IDLE
2073
2136
  }
2074
2137
  ) }) }),
2075
2138
  /* @__PURE__ */ e.jsxs("div", { className: "iw iw-bg-[#F6F6F6] iw-grid iw-grid-cols-2 iw-rounded-[14px] iw-p-6", children: [
2076
- /* @__PURE__ */ e.jsx("div", { className: "iw-min-h-[400px] iw-max-h-[600px]", children: /* @__PURE__ */ e.jsx(Et, {}) }),
2139
+ /* @__PURE__ */ e.jsx("div", { className: "iw-min-h-[400px] iw-max-h-[600px]", children: /* @__PURE__ */ e.jsx(Pt, {}) }),
2077
2140
  /* @__PURE__ */ e.jsx("div", { className: "iw-bg-white iw-rounded-r-xl iw-shadow iw-p-6", children: s })
2078
2141
  ] })
2079
2142
  ]
2080
2143
  }
2081
- ), Fe = ({
2082
- isOpen: t,
2144
+ ), Oe = ({
2145
+ isOpen: i,
2083
2146
  onClose: r,
2084
- children: i,
2147
+ children: t,
2085
2148
  title: s,
2086
2149
  showCloseButton: n = !0,
2087
2150
  closeOnOverlayClick: o = !0,
@@ -2089,17 +2152,17 @@ const we = new pt(), bt = (t = {}) => {
2089
2152
  className: l = ""
2090
2153
  }) => {
2091
2154
  if (C(() => {
2092
- if (!t || !a) return;
2155
+ if (!i || !a) return;
2093
2156
  const u = (h) => {
2094
2157
  h.key === "Escape" && r();
2095
2158
  };
2096
2159
  return document.addEventListener("keydown", u), () => document.removeEventListener("keydown", u);
2097
- }, [t, a, r]), C(() => (t ? (document.body.style.overflow = "hidden", document.body.classList.add("interview-widget-container")) : (document.body.style.overflow = "unset", document.body.classList.remove("interview-widget-container")), () => {
2160
+ }, [i, a, r]), C(() => (i ? (document.body.style.overflow = "hidden", document.body.classList.add("interview-widget-container")) : (document.body.style.overflow = "unset", document.body.classList.remove("interview-widget-container")), () => {
2098
2161
  document.body.style.overflow = "unset", document.body.classList.remove("interview-widget-container");
2099
- }), [t]), !t) return null;
2162
+ }), [i]), !i) return null;
2100
2163
  const d = (u) => {
2101
2164
  o && u.target === u.currentTarget && r();
2102
- }, w = /* @__PURE__ */ e.jsxs("div", { className: "iw-fixed iw-inset-0 iw-z-50 iw-flex iw-items-center iw-justify-center", children: [
2165
+ }, c = /* @__PURE__ */ e.jsxs("div", { className: "iw-fixed iw-inset-0 iw-z-50 iw-flex iw-items-center iw-justify-center", children: [
2103
2166
  /* @__PURE__ */ e.jsx(
2104
2167
  "div",
2105
2168
  {
@@ -2151,21 +2214,21 @@ const we = new pt(), bt = (t = {}) => {
2151
2214
  }
2152
2215
  )
2153
2216
  ] }),
2154
- /* @__PURE__ */ e.jsx("div", { className: "iw-p-4 iw-overflow-y-auto", children: i })
2217
+ /* @__PURE__ */ e.jsx("div", { className: "iw-p-4 iw-overflow-y-auto", children: t })
2155
2218
  ]
2156
2219
  }
2157
2220
  )
2158
2221
  ] });
2159
- return $e(w, document.body);
2160
- }, Ct = ({
2161
- confirmExitInterview: t,
2222
+ return Be(c, document.body);
2223
+ }, Lt = ({
2224
+ confirmExitInterview: i,
2162
2225
  isOpen: r,
2163
- onClose: i
2226
+ onClose: t
2164
2227
  }) => /* @__PURE__ */ e.jsx(
2165
- Fe,
2228
+ Oe,
2166
2229
  {
2167
2230
  isOpen: r,
2168
- onClose: i,
2231
+ onClose: t,
2169
2232
  title: "Exit Interview",
2170
2233
  closeOnOverlayClick: !1,
2171
2234
  children: /* @__PURE__ */ e.jsxs("div", { className: "iw-space-y-5", children: [
@@ -2181,7 +2244,7 @@ const we = new pt(), bt = (t = {}) => {
2181
2244
  "button",
2182
2245
  {
2183
2246
  className: "iw-inline-flex iw-items-center iw-justify-center iw-rounded-lg iw-border iw-border-slate-200 iw-bg-white iw-px-4 iw-py-2 iw-text-sm iw-font-medium iw-text-slate-600 iw-shadow-sm iw-transition hover:iw-bg-slate-50",
2184
- onClick: i,
2247
+ onClick: t,
2185
2248
  children: "Stay in interview"
2186
2249
  }
2187
2250
  ),
@@ -2193,15 +2256,15 @@ const we = new pt(), bt = (t = {}) => {
2193
2256
  background: "linear-gradient(to right, rgba(244, 63, 94, 0.8), rgba(225, 29, 72, 0.8))",
2194
2257
  boxShadow: "0 12px 30px -16px rgba(244, 63, 94, 0.65)"
2195
2258
  },
2196
- onClick: t,
2259
+ onClick: i,
2197
2260
  children: "Confirm exit"
2198
2261
  }
2199
2262
  )
2200
2263
  ] })
2201
2264
  ] })
2202
2265
  }
2203
- ), ye = ({ title: t, onExit: r }) => {
2204
- const { baseColor: i } = Z(), [s, n] = k(!1);
2266
+ ), ke = ({ title: i, onExit: r }) => {
2267
+ const { baseColor: t } = Z(), [s, n] = k(!1);
2205
2268
  return /* @__PURE__ */ e.jsxs("header", { className: "iw-w-full iw-text-gray-900", children: [
2206
2269
  /* @__PURE__ */ e.jsxs("div", { className: "iw-mx-auto iw-flex iw-items-center iw-justify-between iw-px-4 iw-pb-4 iw-pt-2", children: [
2207
2270
  /* @__PURE__ */ e.jsxs("div", { className: "iw-flex iw-items-center iw-space-x-2", children: [
@@ -2209,13 +2272,13 @@ const we = new pt(), bt = (t = {}) => {
2209
2272
  "div",
2210
2273
  {
2211
2274
  className: "iw-h-7 iw-w-7 iw-rounded-md iw-flex iw-items-center iw-justify-center iw-text-white iw-font-semibold",
2212
- style: { backgroundColor: i },
2275
+ style: { backgroundColor: t },
2213
2276
  children: "N"
2214
2277
  }
2215
2278
  ),
2216
2279
  /* @__PURE__ */ e.jsx("p", { className: "iw-text-sm iw-font-medium", children: "Novara" })
2217
2280
  ] }),
2218
- /* @__PURE__ */ e.jsx("h1", { className: "iw-text-base iw-font-bold", children: t }),
2281
+ /* @__PURE__ */ e.jsx("h1", { className: "iw-text-base iw-font-bold", children: i }),
2219
2282
  /* @__PURE__ */ e.jsx(
2220
2283
  "button",
2221
2284
  {
@@ -2230,7 +2293,7 @@ const we = new pt(), bt = (t = {}) => {
2230
2293
  ] }),
2231
2294
  /* @__PURE__ */ e.jsx("div", { className: "iw-h-px iw-bg-gray-200" }),
2232
2295
  /* @__PURE__ */ e.jsx(
2233
- Ct,
2296
+ Lt,
2234
2297
  {
2235
2298
  isOpen: s,
2236
2299
  confirmExitInterview: () => {
@@ -2240,10 +2303,10 @@ const we = new pt(), bt = (t = {}) => {
2240
2303
  }
2241
2304
  )
2242
2305
  ] });
2243
- }, St = ({
2244
- className: t = "",
2306
+ }, $t = ({
2307
+ className: i = "",
2245
2308
  width: r,
2246
- height: i = 56,
2309
+ height: t = 56,
2247
2310
  barWidth: s = 3,
2248
2311
  gap: n = 2,
2249
2312
  fftSize: o = 1024,
@@ -2251,28 +2314,28 @@ const we = new pt(), bt = (t = {}) => {
2251
2314
  mediaStream: l,
2252
2315
  startOnMount: d = !0
2253
2316
  }) => {
2254
- const { baseColor: w } = Z(), u = T(null), h = T(null), m = T(null), c = T(null), x = T(null), y = T(null), j = T(!1), [f, E] = k(null);
2317
+ const { baseColor: c } = Z(), u = T(null), h = T(null), m = T(null), w = T(null), f = T(null), v = T(null), j = T(!1), [x, E] = k(null);
2255
2318
  C(() => {
2256
2319
  if (r || !h.current) return;
2257
- const v = h.current, F = () => {
2320
+ const y = h.current, P = () => {
2258
2321
  const D = u.current;
2259
2322
  if (!D) return;
2260
- const M = v.clientWidth, g = i;
2261
- D.width = Math.max(1, Math.floor(M * window.devicePixelRatio || 1)), D.height = Math.max(1, Math.floor(g * window.devicePixelRatio || 1));
2262
- }, b = new ResizeObserver(F);
2263
- return b.observe(v), F(), () => b.disconnect();
2264
- }, [r, i]), C(() => {
2323
+ const A = y.clientWidth, g = t;
2324
+ D.width = Math.max(1, Math.floor(A * window.devicePixelRatio || 1)), D.height = Math.max(1, Math.floor(g * window.devicePixelRatio || 1));
2325
+ }, b = new ResizeObserver(P);
2326
+ return b.observe(y), P(), () => b.disconnect();
2327
+ }, [r, t]), C(() => {
2265
2328
  if (!r) return;
2266
- const v = u.current;
2267
- v && (v.width = Math.max(
2329
+ const y = u.current;
2330
+ y && (y.width = Math.max(
2268
2331
  1,
2269
2332
  Math.floor(r * (window.devicePixelRatio || 1))
2270
- ), v.height = Math.max(
2333
+ ), y.height = Math.max(
2271
2334
  1,
2272
- Math.floor(i * (window.devicePixelRatio || 1))
2335
+ Math.floor(t * (window.devicePixelRatio || 1))
2273
2336
  ));
2274
- }, [r, i]), C(() => {
2275
- let v = !1;
2337
+ }, [r, t]), C(() => {
2338
+ let y = !1;
2276
2339
  return (async () => {
2277
2340
  try {
2278
2341
  const b = new (window.AudioContext || window.webkitAudioContext)();
@@ -2285,66 +2348,66 @@ const we = new pt(), bt = (t = {}) => {
2285
2348
  video: !1
2286
2349
  }), j.current = !0;
2287
2350
  }
2288
- if (v) return;
2289
- const M = b.createAnalyser();
2290
- M.fftSize = o, M.smoothingTimeConstant = a, c.current = M;
2351
+ if (y) return;
2352
+ const A = b.createAnalyser();
2353
+ A.fftSize = o, A.smoothingTimeConstant = a, w.current = A;
2291
2354
  const g = b.createMediaStreamSource(D);
2292
- x.current = g, g.connect(M), S();
2355
+ f.current = g, g.connect(A), S();
2293
2356
  } catch (b) {
2294
2357
  E((b == null ? void 0 : b.message) || "Failed to initialize microphone");
2295
2358
  }
2296
2359
  })(), () => {
2297
- var b, D, M, g;
2298
- v = !0, y.current && cancelAnimationFrame(y.current);
2360
+ var b, D, A, g;
2361
+ y = !0, v.current && cancelAnimationFrame(v.current);
2299
2362
  try {
2300
- (b = x.current) == null || b.disconnect();
2363
+ (b = f.current) == null || b.disconnect();
2301
2364
  } catch {
2302
2365
  }
2303
2366
  try {
2304
- (D = c.current) == null || D.disconnect();
2367
+ (D = w.current) == null || D.disconnect();
2305
2368
  } catch {
2306
2369
  }
2307
- j.current && ((g = ((M = x.current) == null ? void 0 : M.mediaStream) || void 0) == null || g.getTracks().forEach((I) => I.stop())), m.current && m.current.state !== "closed" && m.current.close();
2370
+ j.current && ((g = ((A = f.current) == null ? void 0 : A.mediaStream) || void 0) == null || g.getTracks().forEach((I) => I.stop())), m.current && m.current.state !== "closed" && m.current.close();
2308
2371
  };
2309
2372
  }, [l, o, a, d]);
2310
2373
  const S = () => {
2311
- const v = u.current, F = c.current;
2312
- if (!v || !F) return;
2313
- const b = v.getContext("2d");
2374
+ const y = u.current, P = w.current;
2375
+ if (!y || !P) return;
2376
+ const b = y.getContext("2d");
2314
2377
  if (!b) return;
2315
- const D = window.devicePixelRatio || 1, M = v.width, g = v.height, I = F.frequencyBinCount, L = new Uint8Array(I), z = () => {
2316
- y.current = requestAnimationFrame(z), F.getByteTimeDomainData(L), b.clearRect(0, 0, M, g), b.fillStyle = "rgba(0,0,0,0)", b.fillRect(0, 0, M, g);
2317
- const U = Math.max(1, Math.floor(s * D)), V = Math.max(1, Math.floor(n * D)), H = U + V, O = Math.max(8, Math.floor((M + V) / H)), G = Math.floor(L.length / O);
2318
- for (let A = 0; A < O; A++) {
2319
- const Q = Math.min(L.length - 1, A * G), oe = L[Q] / 128 - 1, B = Math.abs(oe), le = Math.pow(B, 0.6), Y = Math.max(g * 0.06, le * (g * 0.9)), ce = A * H, de = (g - Y) / 2, K = 140 - Math.min(140, 140 * B), ee = 85, p = 48 + Math.floor(12 * (1 - B));
2320
- b.fillStyle = `${w}`, b.shadowColor = `hsla(${K}, ${ee}%, ${p}%, ${0.25 * B})`, b.shadowBlur = 8 * B;
2321
- const q = Math.min(U / 2, Y / 2);
2322
- It(b, ce, de, U, Y, q), b.fill();
2378
+ const D = window.devicePixelRatio || 1, A = y.width, g = y.height, I = P.frequencyBinCount, L = new Uint8Array(I), B = () => {
2379
+ v.current = requestAnimationFrame(B), P.getByteTimeDomainData(L), b.clearRect(0, 0, A, g), b.fillStyle = "rgba(0,0,0,0)", b.fillRect(0, 0, A, g);
2380
+ const q = Math.max(1, Math.floor(s * D)), z = Math.max(1, Math.floor(n * D)), H = q + z, O = Math.max(8, Math.floor((A + z) / H)), G = Math.floor(L.length / O);
2381
+ for (let M = 0; M < O; M++) {
2382
+ const Y = Math.min(L.length - 1, M * G), oe = L[Y] / 128 - 1, W = Math.abs(oe), le = Math.pow(W, 0.6), Q = Math.max(g * 0.06, le * (g * 0.9)), ce = M * H, de = (g - Q) / 2, K = 140 - Math.min(140, 140 * W), ee = 85, p = 48 + Math.floor(12 * (1 - W));
2383
+ b.fillStyle = `${c}`, b.shadowColor = `hsla(${K}, ${ee}%, ${p}%, ${0.25 * W})`, b.shadowBlur = 8 * W;
2384
+ const U = Math.min(q / 2, Q / 2);
2385
+ Ot(b, ce, de, q, Q, U), b.fill();
2323
2386
  }
2324
2387
  };
2325
- z();
2388
+ B();
2326
2389
  };
2327
2390
  return /* @__PURE__ */ e.jsxs(
2328
2391
  "div",
2329
2392
  {
2330
2393
  ref: h,
2331
- className: `iw-relative iw-w-full iw-overflow-hidden iw-rounded-md iw-bg-gray-50 ${t}`,
2332
- style: { height: i },
2394
+ className: `iw-relative iw-w-full iw-overflow-hidden iw-rounded-md iw-bg-gray-50 ${i}`,
2395
+ style: { height: t },
2333
2396
  children: [
2334
2397
  /* @__PURE__ */ e.jsx("canvas", { ref: u, className: "iw-w-full iw-h-full" }),
2335
- f && /* @__PURE__ */ e.jsx("div", { className: "iw-absolute iw-inset-0 iw-flex iw-items-center iw-justify-center", children: /* @__PURE__ */ e.jsx("span", { className: "iw-text-xs iw-text-red-600 iw-bg-red-50 iw-border iw-border-red-200 iw-px-2 iw-py-1 iw-rounded", children: f }) })
2398
+ x && /* @__PURE__ */ e.jsx("div", { className: "iw-absolute iw-inset-0 iw-flex iw-items-center iw-justify-center", children: /* @__PURE__ */ e.jsx("span", { className: "iw-text-xs iw-text-red-600 iw-bg-red-50 iw-border iw-border-red-200 iw-px-2 iw-py-1 iw-rounded", children: x }) })
2336
2399
  ]
2337
2400
  }
2338
2401
  );
2339
2402
  };
2340
- function It(t, r, i, s, n, o) {
2403
+ function Ot(i, r, t, s, n, o) {
2341
2404
  const a = Math.min(o, s / 2, n / 2);
2342
- t.beginPath(), t.moveTo(r + a, i), t.lineTo(r + s - a, i), t.quadraticCurveTo(r + s, i, r + s, i + a), t.lineTo(r + s, i + n - a), t.quadraticCurveTo(r + s, i + n, r + s - a, i + n), t.lineTo(r + a, i + n), t.quadraticCurveTo(r, i + n, r, i + n - a), t.lineTo(r, i + a), t.quadraticCurveTo(r, i, r + a, i), t.closePath();
2405
+ i.beginPath(), i.moveTo(r + a, t), i.lineTo(r + s - a, t), i.quadraticCurveTo(r + s, t, r + s, t + a), i.lineTo(r + s, t + n - a), i.quadraticCurveTo(r + s, t + n, r + s - a, t + n), i.lineTo(r + a, t + n), i.quadraticCurveTo(r, t + n, r, t + n - a), i.lineTo(r, t + a), i.quadraticCurveTo(r, t, r + a, t), i.closePath();
2343
2406
  }
2344
- const Rt = ({
2345
- state: t,
2407
+ const Ut = ({
2408
+ state: i,
2346
2409
  answeringTime: r,
2347
- nextPhase: i,
2410
+ nextPhase: t,
2348
2411
  sttError: s
2349
2412
  }) => /* @__PURE__ */ e.jsxs("div", { className: "iw-flex iw-flex-col iw-justify-between iw-h-full ", children: [
2350
2413
  /* @__PURE__ */ e.jsxs("div", { children: [
@@ -2352,14 +2415,14 @@ const Rt = ({
2352
2415
  /* @__PURE__ */ e.jsx("h3", { className: "iw-text-lg iw-font-semibold iw-text-gray-900 iw-mb-1", children: "You may start speaking now. We're listening...." }),
2353
2416
  /* @__PURE__ */ e.jsxs("div", { className: "iw-flex iw-items-center iw-justify-center iw-gap-2", children: [
2354
2417
  /* @__PURE__ */ e.jsxs("div", { className: "iw-flex iw-items-center iw-gap-1", children: [
2355
- /* @__PURE__ */ e.jsx(me, { className: "iw-size-4 iw-text-orange-600" }),
2418
+ /* @__PURE__ */ e.jsx(pe, { className: "iw-size-4 iw-text-orange-600" }),
2356
2419
  /* @__PURE__ */ e.jsx("p", { className: "iw-text-gray-700 iw-text-sm", children: "Time to talk: " })
2357
2420
  ] }),
2358
2421
  /* @__PURE__ */ e.jsx(
2359
- ge,
2422
+ be,
2360
2423
  {
2361
2424
  total: r,
2362
- remaining: t.currentPhaseTimeRemaining,
2425
+ remaining: i.currentPhaseTimeRemaining,
2363
2426
  size: 50,
2364
2427
  strokeWidth: 4
2365
2428
  }
@@ -2369,24 +2432,24 @@ const Rt = ({
2369
2432
  /* @__PURE__ */ e.jsx("p", { className: "iw-max-w-lg iw-text-gray-500 iw-text-xs iw-leading-[21px]", children: "Done talking? Click the button to review your answer." })
2370
2433
  ] }),
2371
2434
  /* @__PURE__ */ e.jsxs("div", { children: [
2372
- /* @__PURE__ */ e.jsx(St, {}),
2435
+ /* @__PURE__ */ e.jsx($t, {}),
2373
2436
  s && /* @__PURE__ */ e.jsxs("div", { className: "iw-mt-2 iw-text-xs iw-text-red-600", children: [
2374
2437
  "Recording error: ",
2375
2438
  s.message
2376
2439
  ] })
2377
2440
  ] }),
2378
2441
  /* @__PURE__ */ e.jsx("div", { className: "iw-w-full iw-grid iw-grid-cols-1", children: /* @__PURE__ */ e.jsx(
2379
- W,
2442
+ V,
2380
2443
  {
2381
2444
  onClick: () => {
2382
- i();
2445
+ t();
2383
2446
  },
2384
2447
  children: "Transcribe My Answer"
2385
2448
  }
2386
2449
  ) })
2387
2450
  ] });
2388
- function Mt() {
2389
- const [t, r] = k(!0), i = X(
2451
+ function qt() {
2452
+ const [i, r] = k(!0), t = X(
2390
2453
  () => [0, 1, 2].map((s) => ({ id: s })),
2391
2454
  []
2392
2455
  );
@@ -2396,8 +2459,8 @@ function Mt() {
2396
2459
  }, 1500);
2397
2460
  return () => clearInterval(s);
2398
2461
  }, []), /* @__PURE__ */ e.jsxs("div", { className: "iw-flex iw-flex-col iw-items-center iw-justify-center iw-gap-8 iw-h-full", children: [
2399
- /* @__PURE__ */ e.jsx("div", { className: "iw-relative iw-w-80 iw-h-48 ", "aria-hidden": !0, children: i.map((s, n) => {
2400
- const o = n * 50, a = t ? o : o + 12, l = t ? 1 : 0.08, d = n * 140;
2462
+ /* @__PURE__ */ e.jsx("div", { className: "iw-relative iw-w-80 iw-h-48 ", "aria-hidden": !0, children: t.map((s, n) => {
2463
+ const o = n * 50, a = i ? o : o + 12, l = i ? 1 : 0.08, d = n * 140;
2401
2464
  return /* @__PURE__ */ e.jsx(
2402
2465
  "div",
2403
2466
  {
@@ -2423,10 +2486,10 @@ function Mt() {
2423
2486
  /* @__PURE__ */ e.jsx("div", { className: "iw-text-center", children: /* @__PURE__ */ e.jsx("p", { className: "iw-text-gray-500 iw-font-medium", children: "Preparing your question..." }) })
2424
2487
  ] });
2425
2488
  }
2426
- const At = ({
2427
- size: t = "192px",
2489
+ const Bt = ({
2490
+ size: i = "192px",
2428
2491
  className: r,
2429
- colors: i,
2492
+ colors: t,
2430
2493
  animationDuration: s = 20
2431
2494
  }) => {
2432
2495
  const o = { ...{
@@ -2437,14 +2500,14 @@ const At = ({
2437
2500
  // Pastel blue
2438
2501
  c3: "oklch(78% 0.14 280)"
2439
2502
  // Pastel purple/lavender
2440
- }, ...i }, a = parseInt(t.replace("px", ""), 10), l = a < 50 ? Math.max(a * 8e-3, 1) : Math.max(a * 0.015, 4), d = a < 50 ? Math.max(a * 4e-3, 1.2) : Math.max(a * 8e-3, 1.5), w = a < 50 ? Math.max(a * 4e-3, 0.05) : Math.max(a * 8e-3, 0.1), u = a < 50 ? Math.max(a * 4e-3, 0.5) : Math.max(a * 8e-3, 2), h = a < 30 ? "0%" : a < 50 ? "5%" : a < 100 ? "15%" : "25%", m = a < 30 ? 1.1 : a < 50 ? Math.max(d * 1.2, 1.3) : d;
2503
+ }, ...t }, a = parseInt(i.replace("px", ""), 10), l = a < 50 ? Math.max(a * 8e-3, 1) : Math.max(a * 0.015, 4), d = a < 50 ? Math.max(a * 4e-3, 1.2) : Math.max(a * 8e-3, 1.5), c = a < 50 ? Math.max(a * 4e-3, 0.05) : Math.max(a * 8e-3, 0.1), u = a < 50 ? Math.max(a * 4e-3, 0.5) : Math.max(a * 8e-3, 2), h = a < 30 ? "0%" : a < 50 ? "5%" : a < 100 ? "15%" : "25%", m = a < 30 ? 1.1 : a < 50 ? Math.max(d * 1.2, 1.3) : d;
2441
2504
  return /* @__PURE__ */ e.jsx(
2442
2505
  "div",
2443
2506
  {
2444
2507
  className: `siri-orb ${r}`,
2445
2508
  style: {
2446
- width: t,
2447
- height: t,
2509
+ width: i,
2510
+ height: i,
2448
2511
  "--bg": o.bg,
2449
2512
  "--c1": o.c1,
2450
2513
  "--c2": o.c2,
@@ -2452,7 +2515,7 @@ const At = ({
2452
2515
  "--animation-duration": `${s}s`,
2453
2516
  "--blur-amount": `${l}px`,
2454
2517
  "--contrast-amount": m,
2455
- "--dot-size": `${w}px`,
2518
+ "--dot-size": `${c}px`,
2456
2519
  "--shadow-spread": `${u}px`,
2457
2520
  "--mask-radius": h
2458
2521
  },
@@ -2565,46 +2628,46 @@ const At = ({
2565
2628
  }
2566
2629
  );
2567
2630
  };
2568
- function Dt({ ttsError: t }) {
2631
+ function Wt({ ttsError: i }) {
2569
2632
  return /* @__PURE__ */ e.jsxs("div", { className: "iw-flex iw-flex-col iw-items-center iw-justify-center iw-gap-8 iw-w-full iw-h-full", children: [
2570
- /* @__PURE__ */ e.jsx(At, { size: "80px" }),
2571
- t && /* @__PURE__ */ e.jsxs("div", { className: "iw-mt-2 iw-text-xs iw-text-red-600", children: [
2633
+ /* @__PURE__ */ e.jsx(Bt, { size: "80px" }),
2634
+ i && /* @__PURE__ */ e.jsxs("div", { className: "iw-mt-2 iw-text-xs iw-text-red-600", children: [
2572
2635
  "Audio playback failed: ",
2573
- t.message
2636
+ i.message
2574
2637
  ] }),
2575
2638
  /* @__PURE__ */ e.jsx("p", { className: "iw-text- iw-text-gray-700", children: "Your AI interviewer is speaking..." })
2576
2639
  ] });
2577
2640
  }
2578
- const Pt = ({ state: t, thinkingTime: r, nextPhase: i }) => /* @__PURE__ */ e.jsxs("div", { className: "iw-flex iw-flex-col iw-gap-6 iw-items-center iw-justify-center iw-text-center iw-h-full ", children: [
2641
+ const Gt = ({ state: i, thinkingTime: r, nextPhase: t }) => /* @__PURE__ */ e.jsxs("div", { className: "iw-flex iw-flex-col iw-gap-6 iw-items-center iw-justify-center iw-text-center iw-h-full ", children: [
2579
2642
  /* @__PURE__ */ e.jsxs("div", { children: [
2580
2643
  /* @__PURE__ */ e.jsx("h3", { className: "iw-text-lg iw-font-semibold iw-text-gray-900 iw-mb-1", children: "Get Ready to Answer" }),
2581
2644
  /* @__PURE__ */ e.jsx("p", { className: "iw-max-w-lg iw-text-gray-500 iw-text-xs iw-leading-[21px]", children: "After 30-seconds thinking time, recording will start automatically, or you can begin recording early by clicking the button below." })
2582
2645
  ] }),
2583
2646
  /* @__PURE__ */ e.jsxs("div", { className: "iw-flex iw-items-center iw-justify-center iw-gap-2", children: [
2584
2647
  /* @__PURE__ */ e.jsxs("div", { className: "iw-flex iw-items-center iw-gap-1", children: [
2585
- /* @__PURE__ */ e.jsx(me, { className: "iw-size-4 iw-text-orange-600" }),
2648
+ /* @__PURE__ */ e.jsx(pe, { className: "iw-size-4 iw-text-orange-600" }),
2586
2649
  /* @__PURE__ */ e.jsx("p", { className: "iw-text-gray-700 iw-text-sm", children: "Time to think: " })
2587
2650
  ] }),
2588
2651
  /* @__PURE__ */ e.jsx(
2589
- ge,
2652
+ be,
2590
2653
  {
2591
2654
  total: r,
2592
- remaining: t.currentPhaseTimeRemaining,
2655
+ remaining: i.currentPhaseTimeRemaining,
2593
2656
  size: 50,
2594
2657
  strokeWidth: 4
2595
2658
  }
2596
2659
  )
2597
2660
  ] }),
2598
2661
  /* @__PURE__ */ e.jsx("div", { className: "iw-w-full iw-grid iw-grid-cols-1", children: /* @__PURE__ */ e.jsx(
2599
- W,
2662
+ V,
2600
2663
  {
2601
2664
  onClick: () => {
2602
- i();
2665
+ t();
2603
2666
  },
2604
2667
  children: "Start Answering"
2605
2668
  }
2606
2669
  ) })
2607
- ] }), Ft = ({ sttError: t }) => /* @__PURE__ */ e.jsxs("div", { className: "iw-flex iw-flex-col iw-items-center iw-justify-center iw-h-full", children: [
2670
+ ] }), Vt = ({ sttError: i }) => /* @__PURE__ */ e.jsxs("div", { className: "iw-flex iw-flex-col iw-items-center iw-justify-center iw-h-full", children: [
2608
2671
  /* @__PURE__ */ e.jsxs("svg", { width: "48", height: "48", viewBox: "0 0 60 60", fill: "none", children: [
2609
2672
  /* @__PURE__ */ e.jsx(
2610
2673
  "rect",
@@ -2640,12 +2703,12 @@ const Pt = ({ state: t, thinkingTime: r, nextPhase: i }) => /* @__PURE__ */ e.js
2640
2703
  ] }),
2641
2704
  /* @__PURE__ */ e.jsx("h3", { className: "iw-text-lg iw-font-semibold iw-text-gray-900 iw-mb-1 iw-mt-3", children: "Just a moment... We're analyzing your response" }),
2642
2705
  /* @__PURE__ */ e.jsx("p", { className: "iw-max-w-lg iw-text-gray-500 iw-text-xs iw-leading-[21px]", children: "After transcription, you'll have 45 sec to review your answer." }),
2643
- t && /* @__PURE__ */ e.jsxs("div", { className: "iw-mt-2 iw-text-xs iw-text-red-600", children: [
2706
+ i && /* @__PURE__ */ e.jsxs("div", { className: "iw-mt-2 iw-text-xs iw-text-red-600", children: [
2644
2707
  "Transcription error: ",
2645
- t.message,
2646
- t.recoverable && " (attempting to continue)"
2708
+ i.message,
2709
+ i.recoverable && " (attempting to continue)"
2647
2710
  ] })
2648
- ] }), ie = (t) => /* @__PURE__ */ e.jsxs(
2711
+ ] }), ie = (i) => /* @__PURE__ */ e.jsxs(
2649
2712
  "svg",
2650
2713
  {
2651
2714
  xmlns: "http://www.w3.org/2000/svg",
@@ -2657,14 +2720,14 @@ const Pt = ({ state: t, thinkingTime: r, nextPhase: i }) => /* @__PURE__ */ e.js
2657
2720
  strokeWidth: "2",
2658
2721
  strokeLinecap: "round",
2659
2722
  strokeLinejoin: "round",
2660
- ...t,
2723
+ ...i,
2661
2724
  children: [
2662
2725
  /* @__PURE__ */ e.jsx("path", { d: "m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3" }),
2663
2726
  /* @__PURE__ */ e.jsx("path", { d: "M12 9v4" }),
2664
2727
  /* @__PURE__ */ e.jsx("path", { d: "M12 17h.01" })
2665
2728
  ]
2666
2729
  }
2667
- ), _t = (t) => /* @__PURE__ */ e.jsxs(
2730
+ ), zt = (i) => /* @__PURE__ */ e.jsxs(
2668
2731
  "svg",
2669
2732
  {
2670
2733
  xmlns: "http://www.w3.org/2000/svg",
@@ -2676,13 +2739,13 @@ const Pt = ({ state: t, thinkingTime: r, nextPhase: i }) => /* @__PURE__ */ e.js
2676
2739
  strokeWidth: "2",
2677
2740
  strokeLinecap: "round",
2678
2741
  strokeLinejoin: "round",
2679
- ...t,
2742
+ ...i,
2680
2743
  children: [
2681
2744
  /* @__PURE__ */ e.jsx("path", { d: "M12 6v6l4 2" }),
2682
2745
  /* @__PURE__ */ e.jsx("circle", { cx: "12", cy: "12", r: "10" })
2683
2746
  ]
2684
2747
  }
2685
- ), Lt = (t) => /* @__PURE__ */ e.jsxs(
2748
+ ), Ht = (i) => /* @__PURE__ */ e.jsxs(
2686
2749
  "svg",
2687
2750
  {
2688
2751
  xmlns: "http://www.w3.org/2000/svg",
@@ -2694,13 +2757,13 @@ const Pt = ({ state: t, thinkingTime: r, nextPhase: i }) => /* @__PURE__ */ e.js
2694
2757
  strokeWidth: "2",
2695
2758
  strokeLinecap: "round",
2696
2759
  strokeLinejoin: "round",
2697
- ...t,
2760
+ ...i,
2698
2761
  children: [
2699
2762
  /* @__PURE__ */ e.jsx("path", { d: "M2.062 12.348a1 1 0 0 1 0-.696 10.75 10.75 0 0 1 19.876 0 1 1 0 0 1 0 .696 10.75 10.75 0 0 1-19.876 0" }),
2700
2763
  /* @__PURE__ */ e.jsx("circle", { cx: "12", cy: "12", r: "3" })
2701
2764
  ]
2702
2765
  }
2703
- ), $t = (t) => /* @__PURE__ */ e.jsxs(
2766
+ ), Yt = (i) => /* @__PURE__ */ e.jsxs(
2704
2767
  "svg",
2705
2768
  {
2706
2769
  xmlns: "http://www.w3.org/2000/svg",
@@ -2712,7 +2775,7 @@ const Pt = ({ state: t, thinkingTime: r, nextPhase: i }) => /* @__PURE__ */ e.js
2712
2775
  strokeWidth: "2",
2713
2776
  strokeLinecap: "round",
2714
2777
  strokeLinejoin: "round",
2715
- ...t,
2778
+ ...i,
2716
2779
  children: [
2717
2780
  /* @__PURE__ */ e.jsx("circle", { cx: "12", cy: "12", r: "3" }),
2718
2781
  /* @__PURE__ */ e.jsx("path", { d: "M3 7V5a2 2 0 0 1 2-2h2" }),
@@ -2721,7 +2784,7 @@ const Pt = ({ state: t, thinkingTime: r, nextPhase: i }) => /* @__PURE__ */ e.js
2721
2784
  /* @__PURE__ */ e.jsx("path", { d: "M7 21H5a2 2 0 0 1-2-2v-2" })
2722
2785
  ]
2723
2786
  }
2724
- ), ue = (t) => /* @__PURE__ */ e.jsxs(
2787
+ ), ue = (i) => /* @__PURE__ */ e.jsxs(
2725
2788
  "svg",
2726
2789
  {
2727
2790
  xmlns: "http://www.w3.org/2000/svg",
@@ -2733,7 +2796,7 @@ const Pt = ({ state: t, thinkingTime: r, nextPhase: i }) => /* @__PURE__ */ e.js
2733
2796
  strokeWidth: "2",
2734
2797
  strokeLinecap: "round",
2735
2798
  strokeLinejoin: "round",
2736
- ...t,
2799
+ ...i,
2737
2800
  children: [
2738
2801
  /* @__PURE__ */ e.jsx("circle", { cx: "12", cy: "12", r: "3" }),
2739
2802
  /* @__PURE__ */ e.jsx("path", { d: "M3 7V5a2 2 0 0 1 2-2h2" }),
@@ -2742,7 +2805,7 @@ const Pt = ({ state: t, thinkingTime: r, nextPhase: i }) => /* @__PURE__ */ e.js
2742
2805
  /* @__PURE__ */ e.jsx("path", { d: "M7 21H5a2 2 0 0 1-2-2v-2" })
2743
2806
  ]
2744
2807
  }
2745
- ), Ot = (t) => /* @__PURE__ */ e.jsxs(
2808
+ ), Qt = (i) => /* @__PURE__ */ e.jsxs(
2746
2809
  "svg",
2747
2810
  {
2748
2811
  xmlns: "http://www.w3.org/2000/svg",
@@ -2754,7 +2817,7 @@ const Pt = ({ state: t, thinkingTime: r, nextPhase: i }) => /* @__PURE__ */ e.js
2754
2817
  strokeWidth: "2",
2755
2818
  strokeLinecap: "round",
2756
2819
  strokeLinejoin: "round",
2757
- ...t,
2820
+ ...i,
2758
2821
  children: [
2759
2822
  /* @__PURE__ */ e.jsx("circle", { cx: "12", cy: "12", r: "3" }),
2760
2823
  /* @__PURE__ */ e.jsx("path", { d: "M3 7V5a2 2 0 0 1 2-2h2" }),
@@ -2764,10 +2827,10 @@ const Pt = ({ state: t, thinkingTime: r, nextPhase: i }) => /* @__PURE__ */ e.js
2764
2827
  ]
2765
2828
  }
2766
2829
  ), te = 5;
2767
- function qt({
2768
- isOpen: t,
2830
+ function Kt({
2831
+ isOpen: i,
2769
2832
  onClose: r,
2770
- warningCount: i,
2833
+ warningCount: t,
2771
2834
  violationType: s,
2772
2835
  onDisqualify: n
2773
2836
  }) {
@@ -2775,35 +2838,35 @@ function qt({
2775
2838
  if (C(() => {
2776
2839
  l.current = r;
2777
2840
  }, [r]), C(() => {
2778
- if (!t) return;
2841
+ if (!i) return;
2779
2842
  const m = setInterval(() => {
2780
- a((c) => c <= 1 ? (l.current(), 10) : c - 1);
2843
+ a((w) => w <= 1 ? (l.current(), 10) : w - 1);
2781
2844
  }, 1e3);
2782
2845
  return () => clearInterval(m);
2783
- }, [t]), C(() => {
2784
- t && a(10);
2785
- }, [t]), C(() => (t ? (document.body.style.overflow = "hidden", document.body.classList.add("interview-widget-container")) : (document.body.style.overflow = "unset", document.body.classList.remove("interview-widget-container")), () => {
2846
+ }, [i]), C(() => {
2847
+ i && a(10);
2848
+ }, [i]), C(() => (i ? (document.body.style.overflow = "hidden", document.body.classList.add("interview-widget-container")) : (document.body.style.overflow = "unset", document.body.classList.remove("interview-widget-container")), () => {
2786
2849
  document.body.style.overflow = "unset", document.body.classList.remove("interview-widget-container");
2787
- }), [t]), !t) return null;
2788
- const w = (() => {
2850
+ }), [i]), !i) return null;
2851
+ const c = (() => {
2789
2852
  switch (s) {
2790
2853
  case "tab_switch":
2791
2854
  return {
2792
2855
  title: "Tab Switch Detected",
2793
2856
  description: "You attempted to switch to another tab or reload application.",
2794
- icon: /* @__PURE__ */ e.jsx(Lt, { className: "iw-h-5 iw-w-5" })
2857
+ icon: /* @__PURE__ */ e.jsx(Ht, { className: "iw-h-5 iw-w-5" })
2795
2858
  };
2796
2859
  case "fullscreen_exit":
2797
2860
  return {
2798
2861
  title: "Full Screen Exit Detected",
2799
2862
  description: "You attempted to exit full screen mode.",
2800
- icon: /* @__PURE__ */ e.jsx(Pe, { className: "iw-h-5 iw-w-5" })
2863
+ icon: /* @__PURE__ */ e.jsx($e, { className: "iw-h-5 iw-w-5" })
2801
2864
  };
2802
2865
  case "focus_loss":
2803
2866
  return {
2804
2867
  title: "Focus Loss Detected",
2805
2868
  description: "You lost focus from the interview window.",
2806
- icon: /* @__PURE__ */ e.jsx($t, { className: "iw-h-5 iw-w-5" })
2869
+ icon: /* @__PURE__ */ e.jsx(Yt, { className: "iw-h-5 iw-w-5" })
2807
2870
  };
2808
2871
  case "blocked_shortcut":
2809
2872
  return {
@@ -2815,7 +2878,7 @@ function qt({
2815
2878
  return {
2816
2879
  title: "Right Click Attempted",
2817
2880
  description: "You attempted to use the right click.",
2818
- icon: /* @__PURE__ */ e.jsx(Ot, { className: "iw-h-5 iw-w-5" })
2881
+ icon: /* @__PURE__ */ e.jsx(Qt, { className: "iw-h-5 iw-w-5" })
2819
2882
  };
2820
2883
  case "alt_tab_attempt":
2821
2884
  return {
@@ -2836,8 +2899,8 @@ function qt({
2836
2899
  icon: /* @__PURE__ */ e.jsx(ie, { className: "iw-h-5 iw-w-5" })
2837
2900
  };
2838
2901
  }
2839
- })(), u = te - i, h = () => {
2840
- i + 1 > te ? n() : r();
2902
+ })(), u = te - t, h = () => {
2903
+ t + 1 > te ? n() : r();
2841
2904
  };
2842
2905
  return /* @__PURE__ */ e.jsx("div", { className: "iw-fixed iw-inset-0 iw-z-50 iw-flex iw-items-center iw-justify-center iw-bg-black/60 iw-p-4 iw-backdrop-blur-sm", children: /* @__PURE__ */ e.jsxs("div", { className: "iw-w-full iw-max-w-md iw-rounded-2xl iw-border iw-border-gray-100 iw-bg-white iw-shadow-xl", children: [
2843
2906
  /* @__PURE__ */ e.jsxs("div", { className: "iw-p-6 iw-pb-0", children: [
@@ -2847,16 +2910,16 @@ function qt({
2847
2910
  /* @__PURE__ */ e.jsx("h2", { className: "iw-mb-1 iw-text-xl iw-font-semibold iw-text-gray-900", children: "Security Violation" }),
2848
2911
  /* @__PURE__ */ e.jsxs("div", { className: "iw-flex iw-items-center iw-gap-2", children: [
2849
2912
  /* @__PURE__ */ e.jsx("span", { className: "iw-text-sm iw-text-gray-500", children: "Warning" }),
2850
- /* @__PURE__ */ e.jsx("div", { className: "iw-flex iw-gap-1", children: Array.from({ length: te }).map((m, c) => /* @__PURE__ */ e.jsx(
2913
+ /* @__PURE__ */ e.jsx("div", { className: "iw-flex iw-gap-1", children: Array.from({ length: te }).map((m, w) => /* @__PURE__ */ e.jsx(
2851
2914
  "div",
2852
2915
  {
2853
- className: `iw-h-2 iw-w-2 iw-rounded-full ${c <= i - 1 ? "iw-bg-red-500" : "iw-bg-gray-200"}`
2916
+ className: `iw-h-2 iw-w-2 iw-rounded-full ${w <= t - 1 ? "iw-bg-red-500" : "iw-bg-gray-200"}`
2854
2917
  },
2855
- c
2918
+ w
2856
2919
  )) }),
2857
2920
  /* @__PURE__ */ e.jsxs("span", { className: "iw-text-sm iw-text-gray-500", children: [
2858
2921
  "(",
2859
- i,
2922
+ t,
2860
2923
  "/",
2861
2924
  te,
2862
2925
  ")"
@@ -2873,12 +2936,12 @@ function qt({
2873
2936
  borderColor: "rgb(254, 226, 226)"
2874
2937
  },
2875
2938
  children: /* @__PURE__ */ e.jsxs("div", { className: "iw-flex iw-items-start iw-gap-4", children: [
2876
- /* @__PURE__ */ e.jsx("div", { className: "iw-flex iw-h-10 iw-w-10 iw-items-center iw-justify-center iw-rounded-xl iw-bg-white iw-shadow-sm", children: w.icon }),
2939
+ /* @__PURE__ */ e.jsx("div", { className: "iw-flex iw-h-10 iw-w-10 iw-items-center iw-justify-center iw-rounded-xl iw-bg-white iw-shadow-sm", children: c.icon }),
2877
2940
  /* @__PURE__ */ e.jsxs("div", { className: "iw-flex-1", children: [
2878
- /* @__PURE__ */ e.jsx("h3", { className: "iw-mb-2 iw-font-semibold iw-text-gray-900", children: w.title }),
2879
- /* @__PURE__ */ e.jsx("p", { className: "iw-text-sm iw-leading-relaxed iw-text-gray-700", children: w.description }),
2941
+ /* @__PURE__ */ e.jsx("h3", { className: "iw-mb-2 iw-font-semibold iw-text-gray-900", children: c.title }),
2942
+ /* @__PURE__ */ e.jsx("p", { className: "iw-text-sm iw-leading-relaxed iw-text-gray-700", children: c.description }),
2880
2943
  /* @__PURE__ */ e.jsxs("div", { className: "iw-mt-3 iw-flex iw-items-center iw-gap-2 iw-text-xs iw-text-red-600", children: [
2881
- /* @__PURE__ */ e.jsx(De, { className: "iw-h-3 iw-w-3" }),
2944
+ /* @__PURE__ */ e.jsx(Le, { className: "iw-h-3 iw-w-3" }),
2882
2945
  /* @__PURE__ */ e.jsx("span", { children: "This action is monitored for interview integrity" })
2883
2946
  ] })
2884
2947
  ] })
@@ -2892,7 +2955,7 @@ function qt({
2892
2955
  ] }) }),
2893
2956
  /* @__PURE__ */ e.jsx("div", { className: "iw-border-primary-100 iw-bg-primary-50 iw-rounded-xl iw-border iw-p-4", children: /* @__PURE__ */ e.jsxs("div", { className: "iw-text-center", children: [
2894
2957
  /* @__PURE__ */ e.jsxs("div", { className: "iw-mb-1 iw-flex iw-items-center iw-justify-center iw-gap-1.5", children: [
2895
- /* @__PURE__ */ e.jsx(_t, { className: "iw-text-primary-600 iw-h-4 iw-w-4" }),
2958
+ /* @__PURE__ */ e.jsx(zt, { className: "iw-text-primary-600 iw-h-4 iw-w-4" }),
2896
2959
  /* @__PURE__ */ e.jsx("span", { className: "iw-text-primary-600 iw-text-2xl iw-font-bold", children: o })
2897
2960
  ] }),
2898
2961
  /* @__PURE__ */ e.jsx("div", { className: "iw-text-primary-700 iw-text-xs iw-font-medium", children: "Auto Close" })
@@ -2917,7 +2980,7 @@ function qt({
2917
2980
  ] }),
2918
2981
  /* @__PURE__ */ e.jsxs("div", { className: "iw-p-6 iw-pt-0", children: [
2919
2982
  /* @__PURE__ */ e.jsx(
2920
- W,
2983
+ V,
2921
2984
  {
2922
2985
  onClick: h,
2923
2986
  className: "iw-h-12 iw-w-full iw-rounded-xl iw-bg-gray-800 iw-text-sm iw-font-medium iw-text-white iw-hover:bg-gray-800",
@@ -2928,7 +2991,7 @@ function qt({
2928
2991
  ] })
2929
2992
  ] }) });
2930
2993
  }
2931
- const Ut = (t) => /* @__PURE__ */ e.jsxs(
2994
+ const Jt = (i) => /* @__PURE__ */ e.jsxs(
2932
2995
  "svg",
2933
2996
  {
2934
2997
  xmlns: "http://www.w3.org/2000/svg",
@@ -2940,24 +3003,24 @@ const Ut = (t) => /* @__PURE__ */ e.jsxs(
2940
3003
  strokeWidth: "2",
2941
3004
  strokeLinecap: "round",
2942
3005
  strokeLinejoin: "round",
2943
- ...t,
3006
+ ...i,
2944
3007
  children: [
2945
3008
  /* @__PURE__ */ e.jsx("path", { d: "M9 9.003a1 1 0 0 1 1.517-.859l4.997 2.997a1 1 0 0 1 0 1.718l-4.997 2.997A1 1 0 0 1 9 14.996z" }),
2946
3009
  /* @__PURE__ */ e.jsx("circle", { cx: "12", cy: "12", r: "10" })
2947
3010
  ]
2948
3011
  }
2949
- ), zt = ({
2950
- showHardReloadWarning: t,
3012
+ ), Xt = ({
3013
+ showHardReloadWarning: i,
2951
3014
  onContinue: r
2952
3015
  }) => {
2953
- const i = () => {
3016
+ const t = () => {
2954
3017
  r();
2955
3018
  };
2956
3019
  return /* @__PURE__ */ e.jsxs(
2957
- Fe,
3020
+ Oe,
2958
3021
  {
2959
- isOpen: t,
2960
- onClose: i,
3022
+ isOpen: i,
3023
+ onClose: t,
2961
3024
  closeOnOverlayClick: !1,
2962
3025
  closeOnEscape: !1,
2963
3026
  showCloseButton: !1,
@@ -2972,10 +3035,10 @@ const Ut = (t) => /* @__PURE__ */ e.jsxs(
2972
3035
  /* @__PURE__ */ e.jsx("div", { className: "iw-pt-2 iw-pb-4", children: /* @__PURE__ */ e.jsxs(
2973
3036
  "button",
2974
3037
  {
2975
- onClick: i,
3038
+ onClick: t,
2976
3039
  className: "iw-w-full iw-flex iw-items-center iw-justify-center iw-gap-2 iw-px-4 iw-py-3 iw-bg-gray-100 iw-text-gray-600 iw-rounded-md iw-font-medium iw-transition-colors hover:iw-bg-gray-200 focus:iw-outline-none focus:iw-ring-2 focus:iw-ring-gray-400 focus:iw-ring-offset-2",
2977
3040
  children: [
2978
- /* @__PURE__ */ e.jsx(Ut, { className: "iw-size-4" }),
3041
+ /* @__PURE__ */ e.jsx(Jt, { className: "iw-size-4" }),
2979
3042
  "Continue Session"
2980
3043
  ]
2981
3044
  }
@@ -2983,15 +3046,15 @@ const Ut = (t) => /* @__PURE__ */ e.jsxs(
2983
3046
  ]
2984
3047
  }
2985
3048
  );
2986
- }, Bt = ({ children: t, onDisqualify: r }) => {
2987
- const [i, s] = k(!1), [n, o] = k(!1), [a, l] = k("fullscreen_exit"), { logViolation: d, violationCount: w } = vt({
3049
+ }, Zt = ({ children: i, onDisqualify: r }) => {
3050
+ const [t, s] = k(!1), [n, o] = k(!1), [a, l] = k("fullscreen_exit"), { logViolation: d, violationCount: c } = Rt({
2988
3051
  maxViolations: 5,
2989
- onViolation: (x) => {
2990
- n || (s(!0), l(x.type));
3052
+ onViolation: (f) => {
3053
+ n || (s(!0), l(f.type));
2991
3054
  }
2992
- }), { enterFullScreen: u, isFullScreen: h, exitFullScreen: m } = lt({
2993
- onFullScreenChange(x) {
2994
- !x && !n && (s(!0), d({
3055
+ }), { enterFullScreen: u, isFullScreen: h, exitFullScreen: m } = pt({
3056
+ onFullScreenChange(f) {
3057
+ !f && !n && (s(!0), d({
2995
3058
  type: "fullscreen_exit",
2996
3059
  severity: "high",
2997
3060
  details: {
@@ -3003,26 +3066,26 @@ const Ut = (t) => /* @__PURE__ */ e.jsxs(
3003
3066
  });
3004
3067
  C(() => {
3005
3068
  u();
3006
- }, []), xt(d), ht(d), ft(), yt();
3007
- const c = () => {
3069
+ }, []), Tt(d), Nt(d), Ct(), At();
3070
+ const w = () => {
3008
3071
  o(!0), m(), s(!1), r == null || r();
3009
3072
  };
3010
3073
  return /* @__PURE__ */ e.jsxs(e.Fragment, { children: [
3011
- /* @__PURE__ */ e.jsx("div", { className: "iw-relative iw-h-full iw-w-full", children: t }),
3074
+ /* @__PURE__ */ e.jsx("div", { className: "iw-relative iw-h-full iw-w-full", children: i }),
3012
3075
  /* @__PURE__ */ e.jsx(
3013
- qt,
3076
+ Kt,
3014
3077
  {
3015
- warningCount: w,
3016
- isOpen: i,
3078
+ warningCount: c,
3079
+ isOpen: t,
3017
3080
  violationType: a,
3018
3081
  onClose: () => {
3019
3082
  s(!1), u();
3020
3083
  },
3021
- onDisqualify: c
3084
+ onDisqualify: w
3022
3085
  }
3023
3086
  ),
3024
- !i && w > 0 && !n && /* @__PURE__ */ e.jsx(
3025
- zt,
3087
+ !t && c > 0 && !n && /* @__PURE__ */ e.jsx(
3088
+ Xt,
3026
3089
  {
3027
3090
  showHardReloadWarning: !h,
3028
3091
  logViolation: d,
@@ -3030,48 +3093,48 @@ const Ut = (t) => /* @__PURE__ */ e.jsxs(
3030
3093
  }
3031
3094
  )
3032
3095
  ] });
3033
- }, Gt = ({
3034
- interviewTitle: t,
3096
+ }, ei = ({
3097
+ interviewTitle: i,
3035
3098
  interviewId: r,
3036
- onComplete: i,
3099
+ onComplete: t,
3037
3100
  onDisqualify: s,
3038
3101
  className: n = ""
3039
3102
  }) => {
3040
- const o = ut(), { baseUrl: a, authToken: l } = Se(), { timers: d, stt: w, tts: u, proctoring: h } = He(), [m, c] = k(null), [x, y] = k(""), j = T(""), f = T(null), E = {
3103
+ const o = jt(), { baseUrl: a, authToken: l } = Me(), { timers: d, stt: c, tts: u, proctoring: h } = rt(), [m, w] = k(null), [f, v] = k(""), j = T(""), x = T(null), E = {
3041
3104
  thinkingTime: (d == null ? void 0 : d.thinkingDuration) || 30,
3042
3105
  answeringTime: (d == null ? void 0 : d.answeringDuration) || 120,
3043
3106
  editingTime: (d == null ? void 0 : d.editingDuration) || 30
3044
- }, { thinkingTime: S, answeringTime: v, editingTime: F } = E;
3107
+ }, { thinkingTime: S, answeringTime: y, editingTime: P } = E;
3045
3108
  C(() => {
3046
- j.current = x;
3047
- }, [x]);
3109
+ j.current = f;
3110
+ }, [f]);
3048
3111
  const b = T(!1), {
3049
3112
  speak: D,
3050
- stop: M,
3113
+ stop: A,
3051
3114
  error: g
3052
- } = bt({
3115
+ } = It({
3053
3116
  config: {
3054
3117
  baseUrl: a,
3055
3118
  provider: u == null ? void 0 : u.provider,
3056
3119
  authToken: l
3057
3120
  },
3058
3121
  onEnd: () => {
3059
- b.current = !1, A();
3122
+ b.current = !1, M();
3060
3123
  },
3061
3124
  onError: () => {
3062
- b.current || (b.current = !0, A());
3125
+ b.current || (b.current = !0, M());
3063
3126
  }
3064
3127
  }), I = T(!1), L = T(!1), {
3065
- startRecording: z,
3066
- stopRecording: U,
3067
- transcribe: V,
3128
+ startRecording: B,
3129
+ stopRecording: q,
3130
+ transcribe: z,
3068
3131
  error: H
3069
- } = gt({
3132
+ } = Et({
3070
3133
  config: {
3071
3134
  baseUrl: a,
3072
- provider: w == null ? void 0 : w.provider,
3073
- model: w == null ? void 0 : w.model,
3074
- language: w == null ? void 0 : w.language,
3135
+ provider: c == null ? void 0 : c.provider,
3136
+ model: c == null ? void 0 : c.model,
3137
+ language: c == null ? void 0 : c.language,
3075
3138
  authToken: l
3076
3139
  },
3077
3140
  onStart: () => {
@@ -3080,59 +3143,59 @@ const Ut = (t) => /* @__PURE__ */ e.jsxs(
3080
3143
  onStop: () => {
3081
3144
  },
3082
3145
  onTranscriptionComplete: (p) => {
3083
- y(p.transcript), L.current || (L.current = !0, A());
3146
+ v(p.transcript), L.current || (L.current = !0, M());
3084
3147
  },
3085
3148
  onError: (p) => {
3086
- console.error("STT Error:", p), I.current || (I.current = !0, A());
3149
+ console.error("STT Error:", p), I.current || (I.current = !0, M());
3087
3150
  }
3088
- }), { state: O, startQuestion: G, nextPhase: A, completeInterview: Q } = at({
3151
+ }), { state: O, startQuestion: G, nextPhase: M, completeInterview: Y } = ft({
3089
3152
  config: {
3090
3153
  thinkingDuration: S,
3091
- answeringDuration: v,
3092
- editingDuration: F
3154
+ answeringDuration: y,
3155
+ editingDuration: P
3093
3156
  },
3094
3157
  callbacks: {
3095
3158
  onPhaseChange: (p) => {
3096
3159
  switch (p) {
3097
- case P.FETCHING_QUESTION:
3160
+ case _.FETCHING_QUESTION:
3098
3161
  oe();
3099
3162
  break;
3100
- case P.READING_QUESTION:
3101
- Y();
3163
+ case _.READING_QUESTION:
3164
+ Q();
3102
3165
  break;
3103
- case P.ANSWERING:
3166
+ case _.ANSWERING:
3104
3167
  ce();
3105
3168
  break;
3106
- case P.TRANSCRIBING:
3169
+ case _.TRANSCRIBING:
3107
3170
  de();
3108
3171
  break;
3109
- case P.SUBMITTING:
3172
+ case _.SUBMITTING:
3110
3173
  le();
3111
3174
  break;
3112
3175
  }
3113
3176
  },
3114
3177
  onInterviewEnd: () => {
3115
- i == null || i();
3178
+ t == null || t();
3116
3179
  }
3117
3180
  }
3118
3181
  });
3119
3182
  C(() => {
3120
3183
  G();
3121
3184
  }, []);
3122
- const { execute: oe, loading: B } = ot(
3185
+ const { execute: oe, loading: W } = xt(
3123
3186
  async () => {
3124
- var q, xe;
3187
+ var U, ye;
3125
3188
  const p = await o.generateQuestion({
3126
3189
  interviewId: r,
3127
- question: ((q = f.current) == null ? void 0 : q.question) || "",
3128
- qnaId: ((xe = f.current) == null ? void 0 : xe.qna_id) || "",
3190
+ question: ((U = x.current) == null ? void 0 : U.question) || "",
3191
+ qnaId: ((ye = x.current) == null ? void 0 : ye.qna_id) || "",
3129
3192
  answer: j.current
3130
3193
  });
3131
- return f.current = p.data, p;
3194
+ return x.current = p.data, p;
3132
3195
  },
3133
3196
  {
3134
3197
  onSuccess: async (p) => {
3135
- p && p.data && (y(""), c(p.data), A());
3198
+ p && p.data && (v(""), w(p.data), M());
3136
3199
  },
3137
3200
  onError: (p) => {
3138
3201
  console.error("Failed to fetch questions:", p);
@@ -3140,104 +3203,104 @@ const Ut = (t) => /* @__PURE__ */ e.jsxs(
3140
3203
  }
3141
3204
  ), le = N(async () => {
3142
3205
  G();
3143
- }, [G]), Y = N(async () => {
3206
+ }, [G]), Q = N(async () => {
3144
3207
  var p;
3145
- if ((p = f.current) != null && p.question)
3208
+ if ((p = x.current) != null && p.question)
3146
3209
  try {
3147
- b.current = !1, await D(f.current.question), f.current.is_interview_done && (await Je(2e3), Q());
3148
- } catch (q) {
3149
- console.error("Failed to speak question:", q);
3210
+ b.current = !1, await D(x.current.question), x.current.is_interview_done && (await ot(2e3), Y());
3211
+ } catch (U) {
3212
+ console.error("Failed to speak question:", U);
3150
3213
  }
3151
3214
  else
3152
- A();
3153
- }, [D, A, Q]), ce = N(async () => {
3215
+ M();
3216
+ }, [D, M, Y]), ce = N(async () => {
3154
3217
  try {
3155
- await z(v);
3218
+ await B(y);
3156
3219
  } catch (p) {
3157
- console.error("Failed to start recording:", p), A();
3220
+ console.error("Failed to start recording:", p), M();
3158
3221
  }
3159
- }, [z, A]), de = N(async () => {
3222
+ }, [B, M]), de = N(async () => {
3160
3223
  try {
3161
- const p = await U();
3162
- await V(p);
3224
+ const p = await q();
3225
+ await z(p);
3163
3226
  } catch (p) {
3164
- console.error("STT processing failed:", p), !I.current && !L.current && (I.current = !0, A());
3227
+ console.error("STT processing failed:", p), !I.current && !L.current && (I.current = !0, M());
3165
3228
  }
3166
- }, [U, V, A]), K = N(
3229
+ }, [q, z, M]), K = N(
3167
3230
  async (p) => {
3168
- M(), (await o.generateQuestion({
3231
+ A(), (await o.generateQuestion({
3169
3232
  interviewId: r,
3170
3233
  isInterviewDone: !0
3171
- })).success && (p == null || p(), Q(), sessionStorage.removeItem("proctoring-storage"));
3234
+ })).success && (p == null || p(), Y(), sessionStorage.removeItem(ge));
3172
3235
  },
3173
- [r, M, o]
3236
+ [r, A, o]
3174
3237
  ), ee = () => {
3175
3238
  const { phase: p } = O;
3176
3239
  switch (p) {
3177
- case P.IDLE:
3240
+ case _.IDLE:
3178
3241
  return /* @__PURE__ */ e.jsxs("div", { className: "iw-text-center iw-flex iw-flex-col iw-items-center iw-justify-center iw-gap-2 iw-h-full", children: [
3179
3242
  /* @__PURE__ */ e.jsx("h3", { className: "iw-text-lg iw-font-semibold iw-text-gray-900 iw-mb-1", children: "Ready to start the Interview?" }),
3180
3243
  /* @__PURE__ */ e.jsx("p", { className: "iw-max-w-xl iw-text-gray-500 iw-text-xs iw-leading-[21px]", children: `You will be asked a series of behavioral and technical questions. For each one you'll get a short thinking period, then a timed recording window. We'll transcribe your response so you can review and edit it before submitting. Click "Start Interview" when you're ready.` }),
3181
- /* @__PURE__ */ e.jsx(W, { onClick: G, className: "iw-mt-2 iw-w-40", children: "Start Interview" })
3244
+ /* @__PURE__ */ e.jsx(V, { onClick: G, className: "iw-mt-2 iw-w-40", children: "Start Interview" })
3182
3245
  ] });
3183
- case P.FETCHING_QUESTION:
3184
- return /* @__PURE__ */ e.jsx(Mt, {});
3185
- case P.READING_QUESTION:
3186
- return /* @__PURE__ */ e.jsx(Dt, { ttsError: g });
3187
- case P.THINKING:
3246
+ case _.FETCHING_QUESTION:
3247
+ return /* @__PURE__ */ e.jsx(qt, {});
3248
+ case _.READING_QUESTION:
3249
+ return /* @__PURE__ */ e.jsx(Wt, { ttsError: g });
3250
+ case _.THINKING:
3188
3251
  return /* @__PURE__ */ e.jsx(
3189
- Pt,
3252
+ Gt,
3190
3253
  {
3191
3254
  state: O,
3192
3255
  thinkingTime: S,
3193
- nextPhase: A
3256
+ nextPhase: M
3194
3257
  }
3195
3258
  );
3196
- case P.ANSWERING:
3259
+ case _.ANSWERING:
3197
3260
  return /* @__PURE__ */ e.jsx(
3198
- Rt,
3261
+ Ut,
3199
3262
  {
3200
3263
  state: O,
3201
- answeringTime: v,
3202
- nextPhase: A,
3264
+ answeringTime: y,
3265
+ nextPhase: M,
3203
3266
  sttError: H
3204
3267
  }
3205
3268
  );
3206
- case P.TRANSCRIBING:
3207
- return /* @__PURE__ */ e.jsx(Ft, { sttError: H });
3208
- case P.EDITING:
3209
- case P.SUBMITTING:
3269
+ case _.TRANSCRIBING:
3270
+ return /* @__PURE__ */ e.jsx(Vt, { sttError: H });
3271
+ case _.EDITING:
3272
+ case _.SUBMITTING:
3210
3273
  return /* @__PURE__ */ e.jsx("div", { className: "iw-space-y-4 iw-h-full", children: /* @__PURE__ */ e.jsx(
3211
- kt,
3274
+ _t,
3212
3275
  {
3213
- value: x,
3214
- onChange: (q) => y(q.target.value),
3215
- onSubmit: () => A(),
3216
- isSubmitDisabled: !x.trim() || B,
3276
+ value: f,
3277
+ onChange: (U) => v(U.target.value),
3278
+ onSubmit: () => M(),
3279
+ isSubmitDisabled: !f.trim() || W,
3217
3280
  state: O,
3218
- editingTime: F
3281
+ editingTime: P
3219
3282
  }
3220
3283
  ) });
3221
- case P.COMPLETED:
3284
+ case _.COMPLETED:
3222
3285
  return null;
3223
3286
  default:
3224
3287
  return null;
3225
3288
  }
3226
3289
  };
3227
3290
  return /* @__PURE__ */ e.jsx(e.Fragment, { children: h != null && h.enabled ? /* @__PURE__ */ e.jsxs(
3228
- Bt,
3291
+ Zt,
3229
3292
  {
3230
3293
  onDisqualify: () => K(s),
3231
3294
  children: [
3232
3295
  /* @__PURE__ */ e.jsx(
3233
- ye,
3296
+ ke,
3234
3297
  {
3235
- title: t,
3298
+ title: i,
3236
3299
  onExit: () => K()
3237
3300
  }
3238
3301
  ),
3239
3302
  /* @__PURE__ */ e.jsx(
3240
- ve,
3303
+ Ne,
3241
3304
  {
3242
3305
  currentQuestion: m,
3243
3306
  phase: O.phase,
@@ -3249,14 +3312,14 @@ const Ut = (t) => /* @__PURE__ */ e.jsxs(
3249
3312
  }
3250
3313
  ) : /* @__PURE__ */ e.jsxs(e.Fragment, { children: [
3251
3314
  /* @__PURE__ */ e.jsx(
3252
- ye,
3315
+ ke,
3253
3316
  {
3254
- title: t,
3317
+ title: i,
3255
3318
  onExit: () => K()
3256
3319
  }
3257
3320
  ),
3258
3321
  /* @__PURE__ */ e.jsx(
3259
- ve,
3322
+ Ne,
3260
3323
  {
3261
3324
  currentQuestion: m,
3262
3325
  phase: O.phase,
@@ -3265,33 +3328,33 @@ const Ut = (t) => /* @__PURE__ */ e.jsxs(
3265
3328
  }
3266
3329
  )
3267
3330
  ] }) });
3268
- }, Wt = ({
3269
- title: t,
3331
+ }, ti = ({
3332
+ title: i,
3270
3333
  interviewId: r,
3271
- onInterviewEnd: i,
3334
+ onInterviewEnd: t,
3272
3335
  onInterviewDisqualify: s,
3273
3336
  className: n = ""
3274
3337
  }) => {
3275
- const [o, a] = fe.useState(!1), [l, d] = fe.useState(!0), w = T(null);
3338
+ const [o, a] = he.useState(!1), [l, d] = he.useState(!0), c = T(null);
3276
3339
  return o ? /* @__PURE__ */ e.jsx("div", { className: "interview-widget-container", children: /* @__PURE__ */ e.jsx(
3277
3340
  "div",
3278
3341
  {
3279
- ref: w,
3342
+ ref: c,
3280
3343
  className: `iw-flex iw-flex-col iw-rounded-xl iw-shadow-lg iw-overflow-hidden iw-h-[calc(100vh-1rem)] ${n}`,
3281
3344
  children: /* @__PURE__ */ e.jsx("div", { className: " iw-h-full iw-flex iw-flex-col", children: /* @__PURE__ */ e.jsx(
3282
- Gt,
3345
+ ei,
3283
3346
  {
3284
- interviewTitle: t ?? "Interview",
3347
+ interviewTitle: i ?? "Interview",
3285
3348
  interviewId: r,
3286
3349
  className: n,
3287
- onComplete: i || (() => {
3350
+ onComplete: t || (() => {
3288
3351
  }),
3289
3352
  onDisqualify: s
3290
3353
  }
3291
3354
  ) })
3292
3355
  }
3293
3356
  ) }) : /* @__PURE__ */ e.jsx("div", { className: "interview-widget-container", children: /* @__PURE__ */ e.jsx(
3294
- it,
3357
+ ut,
3295
3358
  {
3296
3359
  isOpen: l,
3297
3360
  onStart: () => {
@@ -3301,11 +3364,11 @@ const Ut = (t) => /* @__PURE__ */ e.jsxs(
3301
3364
  ) });
3302
3365
  };
3303
3366
  typeof window < "u" && (window.InterviewWidget = {
3304
- InterviewWidget: Wt,
3305
- InterviewWidgetProvider: Ve
3367
+ InterviewWidget: ti,
3368
+ InterviewWidgetProvider: it
3306
3369
  });
3307
3370
  export {
3308
- Wt as InterviewWidget,
3309
- Ve as InterviewWidgetProvider,
3310
- Wt as default
3371
+ ti as InterviewWidget,
3372
+ it as InterviewWidgetProvider,
3373
+ ti as default
3311
3374
  };