altcha 0.3.2 → 0.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/altcha.js CHANGED
@@ -1,18 +1,18 @@
1
1
  var nt = Object.defineProperty;
2
2
  var it = (r, e, t) => e in r ? nt(r, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : r[e] = t;
3
3
  var M = (r, e, t) => (it(r, typeof e != "symbol" ? e + "" : e, t), t);
4
- function J() {
4
+ function Q() {
5
5
  }
6
- function Ve(r) {
6
+ function Ge(r) {
7
7
  return r();
8
8
  }
9
- function Re() {
9
+ function Ie() {
10
10
  return /* @__PURE__ */ Object.create(null);
11
11
  }
12
- function q(r) {
13
- r.forEach(Ve);
12
+ function te(r) {
13
+ r.forEach(Ge);
14
14
  }
15
- function Oe(r) {
15
+ function Ue(r) {
16
16
  return typeof r == "function";
17
17
  }
18
18
  function lt(r, e) {
@@ -21,13 +21,13 @@ function lt(r, e) {
21
21
  function ot(r) {
22
22
  return Object.keys(r).length === 0;
23
23
  }
24
- function w(r, e) {
24
+ function y(r, e) {
25
25
  r.appendChild(e);
26
26
  }
27
27
  function st(r, e, t) {
28
28
  const i = ct(r);
29
29
  if (!i.getElementById(e)) {
30
- const l = L("style");
30
+ const l = R("style");
31
31
  l.id = e, l.textContent = t, at(i, l);
32
32
  }
33
33
  }
@@ -42,28 +42,28 @@ function ct(r) {
42
42
  ) : r.ownerDocument;
43
43
  }
44
44
  function at(r, e) {
45
- return w(
45
+ return y(
46
46
  /** @type {Document} */
47
47
  r.head || r,
48
48
  e
49
49
  ), e.sheet;
50
50
  }
51
- function A(r, e, t) {
51
+ function Z(r, e, t) {
52
52
  r.insertBefore(e, t || null);
53
53
  }
54
- function N(r) {
54
+ function S(r) {
55
55
  r.parentNode && r.parentNode.removeChild(r);
56
56
  }
57
- function L(r) {
57
+ function R(r) {
58
58
  return document.createElement(r);
59
59
  }
60
- function P(r) {
60
+ function O(r) {
61
61
  return document.createElementNS("http://www.w3.org/2000/svg", r);
62
62
  }
63
63
  function ft(r) {
64
64
  return document.createTextNode(r);
65
65
  }
66
- function U() {
66
+ function B() {
67
67
  return ft(" ");
68
68
  }
69
69
  function ae(r, e, t, i) {
@@ -90,14 +90,14 @@ function dt(r) {
90
90
  }
91
91
  ), e;
92
92
  }
93
- let Q;
94
- function z(r) {
95
- Q = r;
93
+ let ee;
94
+ function q(r) {
95
+ ee = r;
96
96
  }
97
97
  function ge() {
98
- if (!Q)
98
+ if (!ee)
99
99
  throw new Error("Function called outside component initialization");
100
- return Q;
100
+ return ee;
101
101
  }
102
102
  function gt(r) {
103
103
  ge().$$.on_mount.push(r);
@@ -123,56 +123,56 @@ function bt() {
123
123
  return !0;
124
124
  };
125
125
  }
126
- const X = [], ue = [];
127
- let K = [];
128
- const Se = [], He = /* @__PURE__ */ Promise.resolve();
126
+ const J = [], ue = [];
127
+ let z = [];
128
+ const Se = [], Xe = /* @__PURE__ */ Promise.resolve();
129
129
  let he = !1;
130
- function Pe() {
131
- he || (he = !0, He.then(E));
130
+ function De() {
131
+ he || (he = !0, Xe.then($));
132
132
  }
133
133
  function pt() {
134
- return Pe(), He;
134
+ return De(), Xe;
135
135
  }
136
136
  function de(r) {
137
- K.push(r);
137
+ z.push(r);
138
138
  }
139
139
  const fe = /* @__PURE__ */ new Set();
140
- let Y = 0;
141
- function E() {
142
- if (Y !== 0)
140
+ let K = 0;
141
+ function $() {
142
+ if (K !== 0)
143
143
  return;
144
- const r = Q;
144
+ const r = ee;
145
145
  do {
146
146
  try {
147
- for (; Y < X.length; ) {
148
- const e = X[Y];
149
- Y++, z(e), yt(e.$$);
147
+ for (; K < J.length; ) {
148
+ const e = J[K];
149
+ K++, q(e), yt(e.$$);
150
150
  }
151
151
  } catch (e) {
152
- throw X.length = 0, Y = 0, e;
152
+ throw J.length = 0, K = 0, e;
153
153
  }
154
- for (z(null), X.length = 0, Y = 0; ue.length; )
154
+ for (q(null), J.length = 0, K = 0; ue.length; )
155
155
  ue.pop()();
156
- for (let e = 0; e < K.length; e += 1) {
157
- const t = K[e];
156
+ for (let e = 0; e < z.length; e += 1) {
157
+ const t = z[e];
158
158
  fe.has(t) || (fe.add(t), t());
159
159
  }
160
- K.length = 0;
161
- } while (X.length);
160
+ z.length = 0;
161
+ } while (J.length);
162
162
  for (; Se.length; )
163
163
  Se.pop()();
164
- he = !1, fe.clear(), z(r);
164
+ he = !1, fe.clear(), q(r);
165
165
  }
166
166
  function yt(r) {
167
167
  if (r.fragment !== null) {
168
- r.update(), q(r.before_update);
168
+ r.update(), te(r.before_update);
169
169
  const e = r.dirty;
170
170
  r.dirty = [-1], r.fragment && r.fragment.p(r.ctx, e), r.after_update.forEach(de);
171
171
  }
172
172
  }
173
173
  function vt(r) {
174
174
  const e = [], t = [];
175
- K.forEach((i) => r.indexOf(i) === -1 ? e.push(i) : t.push(i)), t.forEach((i) => i()), K = e;
175
+ z.forEach((i) => r.indexOf(i) === -1 ? e.push(i) : t.push(i)), t.forEach((i) => i()), z = e;
176
176
  }
177
177
  const wt = /* @__PURE__ */ new Set();
178
178
  function _t(r, e) {
@@ -181,58 +181,58 @@ function _t(r, e) {
181
181
  function kt(r, e, t) {
182
182
  const { fragment: i, after_update: l } = r.$$;
183
183
  i && i.m(e, t), de(() => {
184
- const o = r.$$.on_mount.map(Ve).filter(Oe);
185
- r.$$.on_destroy ? r.$$.on_destroy.push(...o) : q(o), r.$$.on_mount = [];
184
+ const o = r.$$.on_mount.map(Ge).filter(Ue);
185
+ r.$$.on_destroy ? r.$$.on_destroy.push(...o) : te(o), r.$$.on_mount = [];
186
186
  }), l.forEach(de);
187
187
  }
188
188
  function xt(r, e) {
189
189
  const t = r.$$;
190
- t.fragment !== null && (vt(t.after_update), q(t.on_destroy), t.fragment && t.fragment.d(e), t.on_destroy = t.fragment = null, t.ctx = []);
190
+ t.fragment !== null && (vt(t.after_update), te(t.on_destroy), t.fragment && t.fragment.d(e), t.on_destroy = t.fragment = null, t.ctx = []);
191
191
  }
192
192
  function Et(r, e) {
193
- r.$$.dirty[0] === -1 && (X.push(r), Pe(), r.$$.dirty.fill(0)), r.$$.dirty[e / 31 | 0] |= 1 << e % 31;
193
+ r.$$.dirty[0] === -1 && (J.push(r), De(), r.$$.dirty.fill(0)), r.$$.dirty[e / 31 | 0] |= 1 << e % 31;
194
194
  }
195
- function $t(r, e, t, i, l, o, s = null, a = [-1]) {
196
- const f = Q;
197
- z(r);
198
- const u = r.$$ = {
195
+ function $t(r, e, t, i, l, o, s = null, f = [-1]) {
196
+ const a = ee;
197
+ q(r);
198
+ const h = r.$$ = {
199
199
  fragment: null,
200
200
  ctx: [],
201
201
  // state
202
202
  props: o,
203
- update: J,
203
+ update: Q,
204
204
  not_equal: l,
205
- bound: Re(),
205
+ bound: Ie(),
206
206
  // lifecycle
207
207
  on_mount: [],
208
208
  on_destroy: [],
209
209
  on_disconnect: [],
210
210
  before_update: [],
211
211
  after_update: [],
212
- context: new Map(e.context || (f ? f.$$.context : [])),
212
+ context: new Map(e.context || (a ? a.$$.context : [])),
213
213
  // everything else
214
- callbacks: Re(),
215
- dirty: a,
214
+ callbacks: Ie(),
215
+ dirty: f,
216
216
  skip_bound: !1,
217
- root: e.target || f.$$.root
217
+ root: e.target || a.$$.root
218
218
  };
219
- s && s(u.root);
220
- let R = !1;
221
- if (u.ctx = t ? t(r, e.props || {}, (m, j, ...Z) => {
222
- const G = Z.length ? Z[0] : j;
223
- return u.ctx && l(u.ctx[m], u.ctx[m] = G) && (!u.skip_bound && u.bound[m] && u.bound[m](G), R && Et(r, m)), j;
224
- }) : [], u.update(), R = !0, q(u.before_update), u.fragment = i ? i(u.ctx) : !1, e.target) {
219
+ s && s(h.root);
220
+ let A = !1;
221
+ if (h.ctx = t ? t(r, e.props || {}, (C, V, ...G) => {
222
+ const U = G.length ? G[0] : V;
223
+ return h.ctx && l(h.ctx[C], h.ctx[C] = U) && (!h.skip_bound && h.bound[C] && h.bound[C](U), A && Et(r, C)), V;
224
+ }) : [], h.update(), A = !0, te(h.before_update), h.fragment = i ? i(h.ctx) : !1, e.target) {
225
225
  if (e.hydrate) {
226
- const m = ut(e.target);
227
- u.fragment && u.fragment.l(m), m.forEach(N);
226
+ const C = ut(e.target);
227
+ h.fragment && h.fragment.l(C), C.forEach(S);
228
228
  } else
229
- u.fragment && u.fragment.c();
230
- e.intro && _t(r.$$.fragment), kt(r, e.target, e.anchor), E();
229
+ h.fragment && h.fragment.c();
230
+ e.intro && _t(r.$$.fragment), kt(r, e.target, e.anchor), $();
231
231
  }
232
- z(f);
232
+ q(a);
233
233
  }
234
- let De;
235
- typeof HTMLElement == "function" && (De = class extends HTMLElement {
234
+ let Oe;
235
+ typeof HTMLElement == "function" && (Oe = class extends HTMLElement {
236
236
  constructor(e, t, i) {
237
237
  super();
238
238
  /** The Svelte component constructor */
@@ -275,17 +275,17 @@ typeof HTMLElement == "function" && (De = class extends HTMLElement {
275
275
  let s;
276
276
  return {
277
277
  c: function() {
278
- s = L("slot"), o !== "default" && c(s, "name", o);
278
+ s = R("slot"), o !== "default" && c(s, "name", o);
279
279
  },
280
280
  /**
281
281
  * @param {HTMLElement} target
282
282
  * @param {HTMLElement} [anchor]
283
283
  */
284
- m: function(u, R) {
285
- A(u, s, R);
284
+ m: function(h, A) {
285
+ Z(h, s, A);
286
286
  },
287
- d: function(u) {
288
- u && N(s);
287
+ d: function(h) {
288
+ h && S(s);
289
289
  }
290
290
  };
291
291
  };
@@ -297,7 +297,7 @@ typeof HTMLElement == "function" && (De = class extends HTMLElement {
297
297
  o in i && (t[o] = [e(o)]);
298
298
  for (const o of this.attributes) {
299
299
  const s = this.$$g_p(o.name);
300
- s in this.$$d || (this.$$d[s] = le(s, o.value, this.$$p_d, "toProp"));
300
+ s in this.$$d || (this.$$d[s] = oe(s, o.value, this.$$p_d, "toProp"));
301
301
  }
302
302
  for (const o in this.$$p_d)
303
303
  !(o in this.$$d) && this[o] !== void 0 && (this.$$d[o] = this[o], delete this[o]);
@@ -315,7 +315,7 @@ typeof HTMLElement == "function" && (De = class extends HTMLElement {
315
315
  this.$$r = !0;
316
316
  for (const o in this.$$p_d)
317
317
  if (this.$$d[o] = this.$$c.$$.ctx[this.$$c.$$.props[o]], this.$$p_d[o].reflect) {
318
- const s = le(
318
+ const s = oe(
319
319
  o,
320
320
  this.$$d[o],
321
321
  this.$$p_d,
@@ -328,8 +328,8 @@ typeof HTMLElement == "function" && (De = class extends HTMLElement {
328
328
  this.$$c.$$.after_update.push(l), l();
329
329
  for (const o in this.$$l)
330
330
  for (const s of this.$$l[o]) {
331
- const a = this.$$c.$on(o, s);
332
- this.$$l_u.set(s, a);
331
+ const f = this.$$c.$on(o, s);
332
+ this.$$l_u.set(s, f);
333
333
  }
334
334
  this.$$l = {};
335
335
  }
@@ -338,7 +338,7 @@ typeof HTMLElement == "function" && (De = class extends HTMLElement {
338
338
  // and setting attributes through setAttribute etc, this is helpful
339
339
  attributeChangedCallback(e, t, i) {
340
340
  var l;
341
- this.$$r || (e = this.$$g_p(e), this.$$d[e] = le(e, i, this.$$p_d, "toProp"), (l = this.$$c) == null || l.$set({ [e]: this.$$d[e] }));
341
+ this.$$r || (e = this.$$g_p(e), this.$$d[e] = oe(e, i, this.$$p_d, "toProp"), (l = this.$$c) == null || l.$set({ [e]: this.$$d[e] }));
342
342
  }
343
343
  disconnectedCallback() {
344
344
  this.$$cn = !1, Promise.resolve().then(() => {
@@ -351,7 +351,7 @@ typeof HTMLElement == "function" && (De = class extends HTMLElement {
351
351
  ) || e;
352
352
  }
353
353
  });
354
- function le(r, e, t, i) {
354
+ function oe(r, e, t, i) {
355
355
  var o;
356
356
  const l = (o = t[r]) == null ? void 0 : o.type;
357
357
  if (e = l === "Boolean" && typeof e != "boolean" ? e != null : e, !i || !t[r])
@@ -382,31 +382,31 @@ function le(r, e, t, i) {
382
382
  }
383
383
  }
384
384
  function Ct(r, e, t, i, l, o) {
385
- let s = class extends De {
385
+ let s = class extends Oe {
386
386
  constructor() {
387
387
  super(r, t, l), this.$$p_d = e;
388
388
  }
389
389
  static get observedAttributes() {
390
390
  return Object.keys(e).map(
391
- (a) => (e[a].attribute || a).toLowerCase()
391
+ (f) => (e[f].attribute || f).toLowerCase()
392
392
  );
393
393
  }
394
394
  };
395
- return Object.keys(e).forEach((a) => {
396
- Object.defineProperty(s.prototype, a, {
395
+ return Object.keys(e).forEach((f) => {
396
+ Object.defineProperty(s.prototype, f, {
397
397
  get() {
398
- return this.$$c && a in this.$$c ? this.$$c[a] : this.$$d[a];
398
+ return this.$$c && f in this.$$c ? this.$$c[f] : this.$$d[f];
399
399
  },
400
- set(f) {
401
- var u;
402
- f = le(a, f, e), this.$$d[a] = f, (u = this.$$c) == null || u.$set({ [a]: f });
400
+ set(a) {
401
+ var h;
402
+ a = oe(f, a, e), this.$$d[f] = a, (h = this.$$c) == null || h.$set({ [f]: a });
403
403
  }
404
404
  });
405
- }), i.forEach((a) => {
406
- Object.defineProperty(s.prototype, a, {
405
+ }), i.forEach((f) => {
406
+ Object.defineProperty(s.prototype, f, {
407
407
  get() {
408
- var f;
409
- return (f = this.$$c) == null ? void 0 : f[a];
408
+ var a;
409
+ return (a = this.$$c) == null ? void 0 : a[f];
410
410
  }
411
411
  });
412
412
  }), o && (s = o(s)), r.element = /** @type {any} */
@@ -433,7 +433,7 @@ class Lt {
433
433
  }
434
434
  /** @returns {void} */
435
435
  $destroy() {
436
- xt(this, 1), this.$destroy = J;
436
+ xt(this, 1), this.$destroy = Q;
437
437
  }
438
438
  /**
439
439
  * @template {Extract<keyof Events, string>} K
@@ -442,8 +442,8 @@ class Lt {
442
442
  * @returns {() => void}
443
443
  */
444
444
  $on(e, t) {
445
- if (!Oe(t))
446
- return J;
445
+ if (!Ue(t))
446
+ return Q;
447
447
  const i = this.$$.callbacks[e] || (this.$$.callbacks[e] = []);
448
448
  return i.push(t), () => {
449
449
  const l = i.indexOf(t);
@@ -458,13 +458,13 @@ class Lt {
458
458
  this.$$set && !ot(e) && (this.$$.skip_bound = !0, this.$$set(e), this.$$.skip_bound = !1);
459
459
  }
460
460
  }
461
- const It = "4";
462
- typeof window < "u" && (window.__svelte || (window.__svelte = { v: /* @__PURE__ */ new Set() })).v.add(It);
463
- const Fe = "KGZ1bmN0aW9uKCl7InVzZSBzdHJpY3QiO2NvbnN0IGY9bmV3IFRleHRFbmNvZGVyO2Z1bmN0aW9uIGcodCl7cmV0dXJuWy4uLm5ldyBVaW50OEFycmF5KHQpXS5tYXAoZT0+ZS50b1N0cmluZygxNikucGFkU3RhcnQoMiwiMCIpKS5qb2luKCIiKX1hc3luYyBmdW5jdGlvbiBoKHQsZSxvKXtyZXR1cm4gZyhhd2FpdCBjcnlwdG8uc3VidGxlLmRpZ2VzdChvLnRvVXBwZXJDYXNlKCksZi5lbmNvZGUodCtlKSkpfWZ1bmN0aW9uIG0odCxlLG89IlNIQS0yNTYiLGk9MWU2LHA9MCl7Y29uc3QgYT1uZXcgQWJvcnRDb250cm9sbGVyO3JldHVybntwcm9taXNlOm5ldyBQcm9taXNlKChzLGMpPT57Y29uc3Qgcj1EYXRlLm5vdygpLGQ9bD0+e2Euc2lnbmFsLmFib3J0ZWR8fGw+aT9zKG51bGwpOmgoZSxsLG8pLnRoZW4odz0+e3c9PT10P3Moe251bWJlcjpsLHRvb2s6RGF0ZS5ub3coKS1yfSk6ZChsKzEpfSkuY2F0Y2goYyl9O2QocCl9KSxjb250cm9sbGVyOmF9fWxldCBuO29ubWVzc2FnZT1hc3luYyB0PT57Y29uc3R7dHlwZTplLHBheWxvYWQ6b309dC5kYXRhO2lmKGU9PT0iYWJvcnQiKW49PW51bGx8fG4uYWJvcnQoKSxuPXZvaWQgMDtlbHNlIGlmKGU9PT0id29yayIpe2NvbnN0e2FsZzppLGNoYWxsZW5nZTpwLG1heDphLHNhbHQ6dSxzdGFydDpzfT1vfHx7fSxjPW0ocCx1LGksYSxzKTtuPWMuY29udHJvbGxlcixjLnByb21pc2UudGhlbihyPT57c2VsZi5wb3N0TWVzc2FnZShyJiZ7Li4ucix3b3JrZXI6ITB9KX0pfX19KSgpOwo=", Rt = (r) => Uint8Array.from(atob(r), (e) => e.charCodeAt(0)), Te = typeof window < "u" && window.Blob && new Blob([Rt(Fe)], { type: "text/javascript;charset=utf-8" });
461
+ const Rt = "4";
462
+ typeof window < "u" && (window.__svelte || (window.__svelte = { v: /* @__PURE__ */ new Set() })).v.add(Rt);
463
+ const Fe = "KGZ1bmN0aW9uKCl7InVzZSBzdHJpY3QiO2NvbnN0IGY9bmV3IFRleHRFbmNvZGVyO2Z1bmN0aW9uIGQoZSl7cmV0dXJuWy4uLm5ldyBVaW50OEFycmF5KGUpXS5tYXAodD0+dC50b1N0cmluZygxNikucGFkU3RhcnQoMiwiMCIpKS5qb2luKCIiKX1hc3luYyBmdW5jdGlvbiBwKGUsdCxvKXtyZXR1cm4gZChhd2FpdCBjcnlwdG8uc3VidGxlLmRpZ2VzdChvLnRvVXBwZXJDYXNlKCksZi5lbmNvZGUoZSt0KSkpfWZ1bmN0aW9uIGcoZSx0LG89IlNIQS0yNTYiLGw9MWU2LGM9MCl7Y29uc3QgYT1uZXcgQWJvcnRDb250cm9sbGVyLGk9RGF0ZS5ub3coKTtyZXR1cm57cHJvbWlzZTooYXN5bmMoKT0+e2ZvcihsZXQgbj1jO248PWw7bis9MSl7aWYoYS5zaWduYWwuYWJvcnRlZClyZXR1cm4gbnVsbDtpZihhd2FpdCBwKHQsbixvKT09PWUpcmV0dXJue251bWJlcjpuLHRvb2s6RGF0ZS5ub3coKS1pfX1yZXR1cm4gbnVsbH0pKCksY29udHJvbGxlcjphfX1sZXQgcjtvbm1lc3NhZ2U9YXN5bmMgZT0+e2NvbnN0e3R5cGU6dCxwYXlsb2FkOm99PWUuZGF0YTtpZih0PT09ImFib3J0IilyPT1udWxsfHxyLmFib3J0KCkscj12b2lkIDA7ZWxzZSBpZih0PT09IndvcmsiKXtjb25zdHthbGc6bCxjaGFsbGVuZ2U6YyxtYXg6YSxzYWx0Omksc3RhcnQ6dX09b3x8e30sbj1nKGMsaSxsLGEsdSk7cj1uLmNvbnRyb2xsZXIsbi5wcm9taXNlLnRoZW4ocz0+e3NlbGYucG9zdE1lc3NhZ2UocyYmey4uLnMsd29ya2VyOiEwfSl9KX19fSkoKTsK", It = (r) => Uint8Array.from(atob(r), (e) => e.charCodeAt(0)), je = typeof window < "u" && window.Blob && new Blob([It(Fe)], { type: "text/javascript;charset=utf-8" });
464
464
  function Nt(r) {
465
465
  let e;
466
466
  try {
467
- if (e = Te && (window.URL || window.webkitURL).createObjectURL(Te), !e)
467
+ if (e = je && (window.URL || window.webkitURL).createObjectURL(je), !e)
468
468
  throw "";
469
469
  const t = new Worker(e, {
470
470
  name: r == null ? void 0 : r.name
@@ -484,13 +484,13 @@ function Nt(r) {
484
484
  }
485
485
  }
486
486
  const St = new TextEncoder();
487
- function Tt(r) {
487
+ function jt(r) {
488
488
  return [...new Uint8Array(r)].map((e) => e.toString(16).padStart(2, "0")).join("");
489
489
  }
490
- async function At(r, e = "SHA-256", t = 1e5) {
490
+ async function Zt(r, e = "SHA-256", t = 1e5) {
491
491
  const i = Date.now().toString(16);
492
492
  r || (r = Math.round(Math.random() * t));
493
- const l = await We(i, r, e);
493
+ const l = await He(i, r, e);
494
494
  return {
495
495
  algorithm: e,
496
496
  challenge: l,
@@ -498,62 +498,63 @@ async function At(r, e = "SHA-256", t = 1e5) {
498
498
  signature: ""
499
499
  };
500
500
  }
501
- async function We(r, e, t) {
502
- return Tt(
501
+ async function He(r, e, t) {
502
+ return jt(
503
503
  await crypto.subtle.digest(
504
504
  t.toUpperCase(),
505
505
  St.encode(r + e)
506
506
  )
507
507
  );
508
508
  }
509
- function jt(r, e, t = "SHA-256", i = 1e6, l = 0) {
510
- const o = new AbortController();
509
+ function At(r, e, t = "SHA-256", i = 1e6, l = 0) {
510
+ const o = new AbortController(), s = Date.now();
511
511
  return {
512
- promise: new Promise((a, f) => {
513
- const u = Date.now(), R = (m) => {
514
- o.signal.aborted || m > i ? a(null) : We(e, m, t).then((j) => {
515
- j === r ? a({
516
- number: m,
517
- took: Date.now() - u
518
- }) : R(m + 1);
519
- }).catch(f);
520
- };
521
- R(l);
522
- }),
512
+ promise: (async () => {
513
+ for (let a = l; a <= i; a += 1) {
514
+ if (o.signal.aborted)
515
+ return null;
516
+ if (await He(e, a, t) === r)
517
+ return {
518
+ number: a,
519
+ took: Date.now() - s
520
+ };
521
+ }
522
+ return null;
523
+ })(),
523
524
  controller: o
524
525
  };
525
526
  }
526
- var v = /* @__PURE__ */ ((r) => (r.ERROR = "error", r.VERIFIED = "verified", r.VERIFYING = "verifying", r.UNVERIFIED = "unverified", r.EXPIRED = "expired", r))(v || {});
527
- function Mt(r) {
527
+ var p = /* @__PURE__ */ ((r) => (r.ERROR = "error", r.VERIFIED = "verified", r.VERIFYING = "verifying", r.UNVERIFIED = "unverified", r.EXPIRED = "expired", r))(p || {});
528
+ function Tt(r) {
528
529
  st(r, "svelte-14ngypa", `.altcha.svelte-14ngypa.svelte-14ngypa{background:var(--altcha-color-base, transparent);border:var(--altcha-border-width, 1px) solid
529
530
  var(--altcha-color-border, #a0a0a0);border-radius:var(--altcha-border-radius, 3px);color:var(--altcha-color-text, currentColor);display:flex;flex-direction:column;max-width:var(--altcha-max-width, 260px);overflow:hidden;position:relative;text-align:left}.altcha.svelte-14ngypa.svelte-14ngypa:focus-within{border-color:var(--altcha-color-border-focus, currentColor)}.altcha-main.svelte-14ngypa.svelte-14ngypa{align-items:center;display:flex;gap:0.4rem;padding:0.7rem}.altcha-label.svelte-14ngypa.svelte-14ngypa{flex-grow:1}.altcha-label.svelte-14ngypa label.svelte-14ngypa{cursor:pointer}.altcha-logo.svelte-14ngypa.svelte-14ngypa{color:currentColor;opacity:0.3}.altcha-logo.svelte-14ngypa.svelte-14ngypa:hover{opacity:1}.altcha-error.svelte-14ngypa.svelte-14ngypa{color:var(--altcha-color-error-text, #f23939);display:flex;font-size:0.85rem;gap:0.3rem;padding:0 0.7rem 0.7rem}.altcha-footer.svelte-14ngypa.svelte-14ngypa{align-items:center;background-color:var(--altcha-color-footer-bg, transparent);display:flex;font-size:0.75rem;opacity:0.4;padding:0.2rem 0.7rem;text-align:right}.altcha-footer.svelte-14ngypa.svelte-14ngypa:hover{opacity:1}.altcha-footer.svelte-14ngypa>.svelte-14ngypa:first-child{flex-grow:1}.altcha-footer.svelte-14ngypa a{color:currentColor}.altcha-checkbox.svelte-14ngypa.svelte-14ngypa{display:flex;align-items:center;height:24px;width:24px}.altcha-checkbox.svelte-14ngypa input.svelte-14ngypa{width:18px;height:18px;margin:0}.altcha-hidden.svelte-14ngypa.svelte-14ngypa{display:none}.altcha-spinner.svelte-14ngypa.svelte-14ngypa{animation:svelte-14ngypa-altcha-spinner 0.75s infinite linear;transform-origin:center}@keyframes svelte-14ngypa-altcha-spinner{100%{transform:rotate(360deg)}}`);
530
531
  }
531
- function Ae(r) {
532
+ function Ze(r) {
532
533
  let e, t, i;
533
534
  return {
534
535
  c() {
535
- e = P("svg"), t = P("path"), i = P("path"), c(t, "d", "M12,1A11,11,0,1,0,23,12,11,11,0,0,0,12,1Zm0,19a8,8,0,1,1,8-8A8,8,0,0,1,12,20Z"), c(t, "fill", "currentColor"), c(t, "opacity", ".25"), c(i, "d", "M12,4a8,8,0,0,1,7.89,6.7A1.53,1.53,0,0,0,21.38,12h0a1.5,1.5,0,0,0,1.48-1.75,11,11,0,0,0-21.72,0A1.5,1.5,0,0,0,2.62,12h0a1.53,1.53,0,0,0,1.49-1.3A8,8,0,0,1,12,4Z"), c(i, "fill", "currentColor"), c(i, "class", "altcha-spinner svelte-14ngypa"), c(e, "width", "24"), c(e, "height", "24"), c(e, "viewBox", "0 0 24 24"), c(e, "xmlns", "http://www.w3.org/2000/svg");
536
+ e = O("svg"), t = O("path"), i = O("path"), c(t, "d", "M12,1A11,11,0,1,0,23,12,11,11,0,0,0,12,1Zm0,19a8,8,0,1,1,8-8A8,8,0,0,1,12,20Z"), c(t, "fill", "currentColor"), c(t, "opacity", ".25"), c(i, "d", "M12,4a8,8,0,0,1,7.89,6.7A1.53,1.53,0,0,0,21.38,12h0a1.5,1.5,0,0,0,1.48-1.75,11,11,0,0,0-21.72,0A1.5,1.5,0,0,0,2.62,12h0a1.53,1.53,0,0,0,1.49-1.3A8,8,0,0,1,12,4Z"), c(i, "fill", "currentColor"), c(i, "class", "altcha-spinner svelte-14ngypa"), c(e, "width", "24"), c(e, "height", "24"), c(e, "viewBox", "0 0 24 24"), c(e, "xmlns", "http://www.w3.org/2000/svg");
536
537
  },
537
538
  m(l, o) {
538
- A(l, e, o), w(e, t), w(e, i);
539
+ Z(l, e, o), y(e, t), y(e, i);
539
540
  },
540
541
  d(l) {
541
- l && N(e);
542
+ l && S(e);
542
543
  }
543
544
  };
544
545
  }
545
- function Zt(r) {
546
+ function Mt(r) {
546
547
  let e, t = (
547
548
  /*_strings*/
548
549
  r[9].label + ""
549
550
  ), i;
550
551
  return {
551
552
  c() {
552
- e = L("label"), c(e, "for", i = /*name*/
553
+ e = R("label"), c(e, "for", i = /*name*/
553
554
  r[3] + "_checkbox"), c(e, "class", "svelte-14ngypa");
554
555
  },
555
556
  m(l, o) {
556
- A(l, e, o), e.innerHTML = t;
557
+ Z(l, e, o), e.innerHTML = t;
557
558
  },
558
559
  p(l, o) {
559
560
  o[0] & /*_strings*/
@@ -563,21 +564,21 @@ function Zt(r) {
563
564
  l[3] + "_checkbox") && c(e, "for", i);
564
565
  },
565
566
  d(l) {
566
- l && N(e);
567
+ l && S(e);
567
568
  }
568
569
  };
569
570
  }
570
- function Gt(r) {
571
+ function Vt(r) {
571
572
  let e, t = (
572
573
  /*_strings*/
573
574
  r[9].verifying + ""
574
575
  );
575
576
  return {
576
577
  c() {
577
- e = L("span");
578
+ e = R("span");
578
579
  },
579
580
  m(i, l) {
580
- A(i, e, l), e.innerHTML = t;
581
+ Z(i, e, l), e.innerHTML = t;
581
582
  },
582
583
  p(i, l) {
583
584
  l[0] & /*_strings*/
@@ -585,18 +586,18 @@ function Gt(r) {
585
586
  i[9].verifying + "") && (e.innerHTML = t);
586
587
  },
587
588
  d(i) {
588
- i && N(e);
589
+ i && S(e);
589
590
  }
590
591
  };
591
592
  }
592
- function Vt(r) {
593
+ function Gt(r) {
593
594
  let e, t = (
594
595
  /*_strings*/
595
596
  r[9].verified + ""
596
597
  ), i, l;
597
598
  return {
598
599
  c() {
599
- e = L("span"), i = U(), l = L("input"), c(l, "type", "hidden"), c(
600
+ e = R("span"), i = B(), l = R("input"), c(l, "type", "hidden"), c(
600
601
  l,
601
602
  "name",
602
603
  /*name*/
@@ -605,7 +606,7 @@ function Vt(r) {
605
606
  r[4];
606
607
  },
607
608
  m(o, s) {
608
- A(o, e, s), e.innerHTML = t, A(o, i, s), A(o, l, s);
609
+ Z(o, e, s), e.innerHTML = t, Z(o, i, s), Z(o, l, s);
609
610
  },
610
611
  p(o, s) {
611
612
  s[0] & /*_strings*/
@@ -621,57 +622,57 @@ function Vt(r) {
621
622
  o[4]);
622
623
  },
623
624
  d(o) {
624
- o && (N(e), N(i), N(l));
625
+ o && (S(e), S(i), S(l));
625
626
  }
626
627
  };
627
628
  }
628
- function je(r) {
629
+ function Ae(r) {
629
630
  let e, t, i, l, o, s;
630
631
  return {
631
632
  c() {
632
- e = L("div"), t = L("a"), i = P("svg"), l = P("path"), o = P("path"), s = P("path"), c(l, "d", "M2.33955 16.4279C5.88954 20.6586 12.1971 21.2105 16.4279 17.6604C18.4699 15.947 19.6548 13.5911 19.9352 11.1365L17.9886 10.4279C17.8738 12.5624 16.909 14.6459 15.1423 16.1284C11.7577 18.9684 6.71167 18.5269 3.87164 15.1423C1.03163 11.7577 1.4731 6.71166 4.8577 3.87164C8.24231 1.03162 13.2883 1.4731 16.1284 4.8577C16.9767 5.86872 17.5322 7.02798 17.804 8.2324L19.9522 9.01429C19.7622 7.07737 19.0059 5.17558 17.6604 3.57212C14.1104 -0.658624 7.80283 -1.21043 3.57212 2.33956C-0.658625 5.88958 -1.21046 12.1971 2.33955 16.4279Z"), c(l, "fill", "currentColor"), c(o, "d", "M3.57212 2.33956C1.65755 3.94607 0.496389 6.11731 0.12782 8.40523L2.04639 9.13961C2.26047 7.15832 3.21057 5.25375 4.8577 3.87164C8.24231 1.03162 13.2883 1.4731 16.1284 4.8577L13.8302 6.78606L19.9633 9.13364C19.7929 7.15555 19.0335 5.20847 17.6604 3.57212C14.1104 -0.658624 7.80283 -1.21043 3.57212 2.33956Z"), c(o, "fill", "currentColor"), c(s, "d", "M7 10H5C5 12.7614 7.23858 15 10 15C12.7614 15 15 12.7614 15 10H13C13 11.6569 11.6569 13 10 13C8.3431 13 7 11.6569 7 10Z"), c(s, "fill", "currentColor"), c(i, "width", "22"), c(i, "height", "22"), c(i, "viewBox", "0 0 20 20"), c(i, "fill", "none"), c(i, "xmlns", "http://www.w3.org/2000/svg"), c(t, "href", Be), c(t, "target", "_blank"), c(t, "class", "altcha-logo svelte-14ngypa");
633
+ e = R("div"), t = R("a"), i = O("svg"), l = O("path"), o = O("path"), s = O("path"), c(l, "d", "M2.33955 16.4279C5.88954 20.6586 12.1971 21.2105 16.4279 17.6604C18.4699 15.947 19.6548 13.5911 19.9352 11.1365L17.9886 10.4279C17.8738 12.5624 16.909 14.6459 15.1423 16.1284C11.7577 18.9684 6.71167 18.5269 3.87164 15.1423C1.03163 11.7577 1.4731 6.71166 4.8577 3.87164C8.24231 1.03162 13.2883 1.4731 16.1284 4.8577C16.9767 5.86872 17.5322 7.02798 17.804 8.2324L19.9522 9.01429C19.7622 7.07737 19.0059 5.17558 17.6604 3.57212C14.1104 -0.658624 7.80283 -1.21043 3.57212 2.33956C-0.658625 5.88958 -1.21046 12.1971 2.33955 16.4279Z"), c(l, "fill", "currentColor"), c(o, "d", "M3.57212 2.33956C1.65755 3.94607 0.496389 6.11731 0.12782 8.40523L2.04639 9.13961C2.26047 7.15832 3.21057 5.25375 4.8577 3.87164C8.24231 1.03162 13.2883 1.4731 16.1284 4.8577L13.8302 6.78606L19.9633 9.13364C19.7929 7.15555 19.0335 5.20847 17.6604 3.57212C14.1104 -0.658624 7.80283 -1.21043 3.57212 2.33956Z"), c(o, "fill", "currentColor"), c(s, "d", "M7 10H5C5 12.7614 7.23858 15 10 15C12.7614 15 15 12.7614 15 10H13C13 11.6569 11.6569 13 10 13C8.3431 13 7 11.6569 7 10Z"), c(s, "fill", "currentColor"), c(i, "width", "22"), c(i, "height", "22"), c(i, "viewBox", "0 0 20 20"), c(i, "fill", "none"), c(i, "xmlns", "http://www.w3.org/2000/svg"), c(t, "href", Ye), c(t, "target", "_blank"), c(t, "class", "altcha-logo svelte-14ngypa");
633
634
  },
634
- m(a, f) {
635
- A(a, e, f), w(e, t), w(t, i), w(i, l), w(i, o), w(i, s);
635
+ m(f, a) {
636
+ Z(f, e, a), y(e, t), y(t, i), y(i, l), y(i, o), y(i, s);
636
637
  },
637
- p: J,
638
- d(a) {
639
- a && N(e);
638
+ p: Q,
639
+ d(f) {
640
+ f && S(e);
640
641
  }
641
642
  };
642
643
  }
643
- function Me(r) {
644
+ function Te(r) {
644
645
  let e, t, i, l;
645
- function o(f, u) {
646
+ function o(a, h) {
646
647
  return (
647
648
  /*state*/
648
- f[5] === v.EXPIRED ? Ht : Ot
649
+ a[5] === p.EXPIRED ? Xt : Ut
649
650
  );
650
651
  }
651
- let s = o(r), a = s(r);
652
+ let s = o(r), f = s(r);
652
653
  return {
653
654
  c() {
654
- e = L("div"), t = P("svg"), i = P("path"), l = U(), a.c(), c(i, "stroke-linecap", "round"), c(i, "stroke-linejoin", "round"), c(i, "d", "M6 18L18 6M6 6l12 12"), c(t, "width", "14"), c(t, "height", "14"), c(t, "xmlns", "http://www.w3.org/2000/svg"), c(t, "fill", "none"), c(t, "viewBox", "0 0 24 24"), c(t, "stroke-width", "1.5"), c(t, "stroke", "currentColor"), c(e, "class", "altcha-error svelte-14ngypa");
655
+ e = R("div"), t = O("svg"), i = O("path"), l = B(), f.c(), c(i, "stroke-linecap", "round"), c(i, "stroke-linejoin", "round"), c(i, "d", "M6 18L18 6M6 6l12 12"), c(t, "width", "14"), c(t, "height", "14"), c(t, "xmlns", "http://www.w3.org/2000/svg"), c(t, "fill", "none"), c(t, "viewBox", "0 0 24 24"), c(t, "stroke-width", "1.5"), c(t, "stroke", "currentColor"), c(e, "class", "altcha-error svelte-14ngypa");
655
656
  },
656
- m(f, u) {
657
- A(f, e, u), w(e, t), w(t, i), w(e, l), a.m(e, null);
657
+ m(a, h) {
658
+ Z(a, e, h), y(e, t), y(t, i), y(e, l), f.m(e, null);
658
659
  },
659
- p(f, u) {
660
- s === (s = o(f)) && a ? a.p(f, u) : (a.d(1), a = s(f), a && (a.c(), a.m(e, null)));
660
+ p(a, h) {
661
+ s === (s = o(a)) && f ? f.p(a, h) : (f.d(1), f = s(a), f && (f.c(), f.m(e, null)));
661
662
  },
662
- d(f) {
663
- f && N(e), a.d();
663
+ d(a) {
664
+ a && S(e), f.d();
664
665
  }
665
666
  };
666
667
  }
667
- function Ot(r) {
668
+ function Ut(r) {
668
669
  let e, t = (
669
670
  /*_strings*/
670
671
  r[9].error + ""
671
672
  );
672
673
  return {
673
674
  c() {
674
- e = L("div"), c(
675
+ e = R("div"), c(
675
676
  e,
676
677
  "title",
677
678
  /*error*/
@@ -679,7 +680,7 @@ function Ot(r) {
679
680
  );
680
681
  },
681
682
  m(i, l) {
682
- A(i, e, l), e.innerHTML = t;
683
+ Z(i, e, l), e.innerHTML = t;
683
684
  },
684
685
  p(i, l) {
685
686
  l[0] & /*_strings*/
@@ -693,18 +694,18 @@ function Ot(r) {
693
694
  );
694
695
  },
695
696
  d(i) {
696
- i && N(e);
697
+ i && S(e);
697
698
  }
698
699
  };
699
700
  }
700
- function Ht(r) {
701
+ function Xt(r) {
701
702
  let e, t = (
702
703
  /*_strings*/
703
704
  r[9].expired + ""
704
705
  );
705
706
  return {
706
707
  c() {
707
- e = L("div"), c(
708
+ e = R("div"), c(
708
709
  e,
709
710
  "title",
710
711
  /*error*/
@@ -712,7 +713,7 @@ function Ht(r) {
712
713
  );
713
714
  },
714
715
  m(i, l) {
715
- A(i, e, l), e.innerHTML = t;
716
+ Z(i, e, l), e.innerHTML = t;
716
717
  },
717
718
  p(i, l) {
718
719
  l[0] & /*_strings*/
@@ -726,21 +727,21 @@ function Ht(r) {
726
727
  );
727
728
  },
728
729
  d(i) {
729
- i && N(e);
730
+ i && S(e);
730
731
  }
731
732
  };
732
733
  }
733
- function Ze(r) {
734
+ function Me(r) {
734
735
  let e, t, i = (
735
736
  /*_strings*/
736
737
  r[9].footer + ""
737
738
  );
738
739
  return {
739
740
  c() {
740
- e = L("div"), t = L("div"), c(t, "class", "svelte-14ngypa"), c(e, "class", "altcha-footer svelte-14ngypa");
741
+ e = R("div"), t = R("div"), c(t, "class", "svelte-14ngypa"), c(e, "class", "altcha-footer svelte-14ngypa");
741
742
  },
742
743
  m(l, o) {
743
- A(l, e, o), w(e, t), t.innerHTML = i;
744
+ Z(l, e, o), y(e, t), t.innerHTML = i;
744
745
  },
745
746
  p(l, o) {
746
747
  o[0] & /*_strings*/
@@ -748,46 +749,46 @@ function Ze(r) {
748
749
  l[9].footer + "") && (t.innerHTML = i);
749
750
  },
750
751
  d(l) {
751
- l && N(e);
752
+ l && S(e);
752
753
  }
753
754
  };
754
755
  }
755
- function Pt(r) {
756
- let e, t, i, l, o, s, a, f, u, R, m, j, Z, G, _ = (
756
+ function Dt(r) {
757
+ let e, t, i, l, o, s, f, a, h, A, C, V, G, U, w = (
757
758
  /*state*/
758
- r[5] === v.VERIFYING && Ae()
759
+ r[5] === p.VERIFYING && Ze()
759
760
  );
760
- function F(d, I) {
761
+ function H(d, I) {
761
762
  return (
762
763
  /*state*/
763
- d[5] === v.VERIFIED ? Vt : (
764
+ d[5] === p.VERIFIED ? Gt : (
764
765
  /*state*/
765
- d[5] === v.VERIFYING ? Gt : Zt
766
+ d[5] === p.VERIFYING ? Vt : Mt
766
767
  )
767
768
  );
768
769
  }
769
- let V = F(r), k = V(r), x = (
770
+ let X = H(r), _ = X(r), k = (
770
771
  /*hidelogo*/
771
- r[2] !== !0 && je()
772
+ r[2] !== !0 && Ae()
772
773
  ), g = (
773
774
  /*error*/
774
775
  (r[8] || /*state*/
775
- r[5] === v.EXPIRED) && Me(r)
776
- ), y = (
776
+ r[5] === p.EXPIRED) && Te(r)
777
+ ), b = (
777
778
  /*_strings*/
778
779
  r[9].footer && /*hidefooter*/
779
- r[1] !== !0 && Ze(r)
780
+ r[1] !== !0 && Me(r)
780
781
  );
781
782
  return {
782
783
  c() {
783
- e = L("div"), t = L("div"), _ && _.c(), i = U(), l = L("div"), o = L("input"), f = U(), u = L("div"), k.c(), R = U(), x && x.c(), m = U(), g && g.c(), j = U(), y && y.c(), c(o, "type", "checkbox"), c(o, "id", s = /*name*/
784
- r[3] + "_checkbox"), o.required = a = /*auto*/
784
+ e = R("div"), t = R("div"), w && w.c(), i = B(), l = R("div"), o = R("input"), a = B(), h = R("div"), _.c(), A = B(), k && k.c(), C = B(), g && g.c(), V = B(), b && b.c(), c(o, "type", "checkbox"), c(o, "id", s = /*name*/
785
+ r[3] + "_checkbox"), o.required = f = /*auto*/
785
786
  r[0] !== "onsubmit", c(o, "class", "svelte-14ngypa"), c(l, "class", "altcha-checkbox svelte-14ngypa"), Ne(
786
787
  l,
787
788
  "altcha-hidden",
788
789
  /*state*/
789
- r[5] === v.VERIFYING
790
- ), c(u, "class", "altcha-label svelte-14ngypa"), c(t, "class", "altcha-main svelte-14ngypa"), c(e, "class", "altcha svelte-14ngypa"), c(
790
+ r[5] === p.VERIFYING
791
+ ), c(h, "class", "altcha-label svelte-14ngypa"), c(t, "class", "altcha-main svelte-14ngypa"), c(e, "class", "altcha svelte-14ngypa"), c(
791
792
  e,
792
793
  "data-state",
793
794
  /*state*/
@@ -795,8 +796,8 @@ function Pt(r) {
795
796
  );
796
797
  },
797
798
  m(d, I) {
798
- A(d, e, I), w(e, t), _ && _.m(t, null), w(t, i), w(t, l), w(l, o), o.checked = /*checked*/
799
- r[6], w(t, f), w(t, u), k.m(u, null), w(t, R), x && x.m(t, null), w(e, m), g && g.m(e, null), w(e, j), y && y.m(e, null), r[30](e), Z || (G = [
799
+ Z(d, e, I), y(e, t), w && w.m(t, null), y(t, i), y(t, l), y(l, o), o.checked = /*checked*/
800
+ r[6], y(t, a), y(t, h), _.m(h, null), y(t, A), k && k.m(t, null), y(e, C), g && g.m(e, null), y(e, V), b && b.m(e, null), r[30](e), G || (U = [
800
801
  ae(
801
802
  o,
802
803
  "change",
@@ -815,28 +816,28 @@ function Pt(r) {
815
816
  /*onInvalid*/
816
817
  r[11]
817
818
  )
818
- ], Z = !0);
819
+ ], G = !0);
819
820
  },
820
821
  p(d, I) {
821
822
  /*state*/
822
- d[5] === v.VERIFYING ? _ || (_ = Ae(), _.c(), _.m(t, i)) : _ && (_.d(1), _ = null), I[0] & /*name*/
823
+ d[5] === p.VERIFYING ? w || (w = Ze(), w.c(), w.m(t, i)) : w && (w.d(1), w = null), I[0] & /*name*/
823
824
  8 && s !== (s = /*name*/
824
825
  d[3] + "_checkbox") && c(o, "id", s), I[0] & /*auto*/
825
- 1 && a !== (a = /*auto*/
826
- d[0] !== "onsubmit") && (o.required = a), I[0] & /*checked*/
826
+ 1 && f !== (f = /*auto*/
827
+ d[0] !== "onsubmit") && (o.required = f), I[0] & /*checked*/
827
828
  64 && (o.checked = /*checked*/
828
829
  d[6]), I[0] & /*state*/
829
830
  32 && Ne(
830
831
  l,
831
832
  "altcha-hidden",
832
833
  /*state*/
833
- d[5] === v.VERIFYING
834
- ), V === (V = F(d)) && k ? k.p(d, I) : (k.d(1), k = V(d), k && (k.c(), k.m(u, null))), /*hidelogo*/
835
- d[2] !== !0 ? x ? x.p(d, I) : (x = je(), x.c(), x.m(t, null)) : x && (x.d(1), x = null), /*error*/
834
+ d[5] === p.VERIFYING
835
+ ), X === (X = H(d)) && _ ? _.p(d, I) : (_.d(1), _ = X(d), _ && (_.c(), _.m(h, null))), /*hidelogo*/
836
+ d[2] !== !0 ? k ? k.p(d, I) : (k = Ae(), k.c(), k.m(t, null)) : k && (k.d(1), k = null), /*error*/
836
837
  d[8] || /*state*/
837
- d[5] === v.EXPIRED ? g ? g.p(d, I) : (g = Me(d), g.c(), g.m(e, j)) : g && (g.d(1), g = null), /*_strings*/
838
+ d[5] === p.EXPIRED ? g ? g.p(d, I) : (g = Te(d), g.c(), g.m(e, V)) : g && (g.d(1), g = null), /*_strings*/
838
839
  d[9].footer && /*hidefooter*/
839
- d[1] !== !0 ? y ? y.p(d, I) : (y = Ze(d), y.c(), y.m(e, null)) : y && (y.d(1), y = null), I[0] & /*state*/
840
+ d[1] !== !0 ? b ? b.p(d, I) : (b = Me(d), b.c(), b.m(e, null)) : b && (b.d(1), b = null), I[0] & /*state*/
840
841
  32 && c(
841
842
  e,
842
843
  "data-state",
@@ -844,18 +845,18 @@ function Pt(r) {
844
845
  d[5]
845
846
  );
846
847
  },
847
- i: J,
848
- o: J,
848
+ i: Q,
849
+ o: Q,
849
850
  d(d) {
850
- d && N(e), _ && _.d(), k.d(), x && x.d(), g && g.d(), y && y.d(), r[30](null), Z = !1, q(G);
851
+ d && S(e), w && w.d(), _.d(), k && k.d(), g && g.d(), b && b.d(), r[30](null), G = !1, te(U);
851
852
  }
852
853
  };
853
854
  }
854
- const Be = "https://altcha.org/";
855
- function Ge(r) {
855
+ const Ye = "https://altcha.org/";
856
+ function Ve(r) {
856
857
  return JSON.parse(r);
857
858
  }
858
- function Dt() {
859
+ function Ot() {
859
860
  try {
860
861
  return Intl.DateTimeFormat().resolvedOptions().timeZone;
861
862
  } catch {
@@ -863,37 +864,37 @@ function Dt() {
863
864
  }
864
865
  function Ft(r, e, t) {
865
866
  var Ee, $e;
866
- let i, l, o, { auto: s = void 0 } = e, { blockspam: a = void 0 } = e, { challengeurl: f = void 0 } = e, { challengejson: u = void 0 } = e, { debug: R = !1 } = e, { expire: m = void 0 } = e, { hidefooter: j = !1 } = e, { hidelogo: Z = !1 } = e, { name: G = "altcha" } = e, { maxnumber: _ = 1e6 } = e, { mockerror: F = !1 } = e, { refetchonexpire: V = !0 } = e, { spamfilter: k = !1 } = e, { strings: x = void 0 } = e, { test: g = !1 } = e, { verifyurl: y = void 0 } = e, { workers: d = navigator.hardwareConcurrency || 8 } = e;
867
+ let i, l, o, { auto: s = void 0 } = e, { blockspam: f = void 0 } = e, { challengeurl: a = void 0 } = e, { challengejson: h = void 0 } = e, { debug: A = !1 } = e, { expire: C = void 0 } = e, { hidefooter: V = !1 } = e, { hidelogo: G = !1 } = e, { name: U = "altcha" } = e, { maxnumber: w = 1e6 } = e, { mockerror: H = !1 } = e, { refetchonexpire: X = !0 } = e, { spamfilter: _ = !1 } = e, { strings: k = void 0 } = e, { test: g = !1 } = e, { verifyurl: b = void 0 } = e, { workers: d = navigator.hardwareConcurrency || 8 } = e;
867
868
  const I = bt(), me = ["SHA-256", "SHA-384", "SHA-512"], be = ($e = (Ee = document.documentElement.lang) == null ? void 0 : Ee.split("-")) == null ? void 0 : $e[0];
868
- let D = !1, ee, b = null, oe = null, W = null, O = v.UNVERIFIED, se;
869
+ let F = !1, re, m = null, se = null, Y = null, D = p.UNVERIFIED, ce;
869
870
  mt(() => {
870
- b && (b.removeEventListener("submit", ye), b.removeEventListener("reset", ve), b.removeEventListener("focusin", pe), b = null);
871
+ m && (m.removeEventListener("submit", ye), m.removeEventListener("reset", ve), m.removeEventListener("focusin", pe), m = null);
871
872
  }), gt(() => {
872
- $("mounted", "0.3.2"), $("workers", d), g && $("using test mode"), m && ce(m), s !== void 0 && $("auto", s), b = ee.closest("form"), b && (b.addEventListener("submit", ye), b.addEventListener("reset", ve), s === "onfocus" && b.addEventListener("focusin", pe)), s === "onload" && B();
873
+ L("mounted", "0.4.0"), L("workers", d), g && L("using test mode"), C && ne(C), s !== void 0 && L("auto", s), m = re.closest("form"), m && (m.addEventListener("submit", ye), m.addEventListener("reset", ve), s === "onfocus" && m.addEventListener("focusin", pe)), s === "onload" && P();
873
874
  });
874
- function $(...n) {
875
- (R || n.some((h) => h instanceof Error)) && console[n[0] instanceof Error ? "error" : "log"]("ALTCHA", ...n);
875
+ function L(...n) {
876
+ (A || n.some((u) => u instanceof Error)) && console[n[0] instanceof Error ? "error" : "log"]("ALTCHA", ...n);
876
877
  }
877
878
  function pe(n) {
878
- B();
879
+ P();
879
880
  }
880
881
  function ye(n) {
881
- b && s === "onsubmit" && O === v.UNVERIFIED && (n.preventDefault(), n.stopPropagation(), B().then(() => {
882
- b == null || b.requestSubmit();
882
+ m && s === "onsubmit" && D === p.UNVERIFIED && (n.preventDefault(), n.stopPropagation(), P().then(() => {
883
+ m == null || m.requestSubmit();
883
884
  }));
884
885
  }
885
886
  function ve() {
886
- te();
887
+ ie();
887
888
  }
888
- function we(n, h) {
889
+ function we(n, u) {
889
890
  return btoa(JSON.stringify({
890
891
  algorithm: n.algorithm,
891
892
  challenge: n.challenge,
892
- number: h.number,
893
+ number: u.number,
893
894
  salt: n.salt,
894
895
  signature: n.signature,
895
896
  test: g ? !0 : void 0,
896
- took: h.took
897
+ took: u.took
897
898
  }));
898
899
  }
899
900
  function _e(n) {
@@ -908,125 +909,130 @@ function Ft(r, e, t) {
908
909
  if (!n.salt || n.salt.length < 10)
909
910
  throw new Error("Salt is too short. Min. 10 chars.");
910
911
  }
911
- async function Ue() {
912
- if (F)
913
- throw $("mocking error"), new Error("Mocked error.");
912
+ async function Pe() {
913
+ var n;
914
+ if (H)
915
+ throw L("mocking error"), new Error("Mocked error.");
914
916
  if (i)
915
- return $("using provided json data"), i;
917
+ return L("using provided json data"), i;
916
918
  if (g)
917
- return $("generating test challenge", { test: g }), At(typeof g != "boolean" ? +g : void 0);
919
+ return L("generating test challenge", { test: g }), Zt(typeof g != "boolean" ? +g : void 0);
918
920
  {
919
- if (!f)
921
+ if (!a)
920
922
  throw new Error("Attribute challengeurl not set.");
921
- $("fetching challenge from", f);
922
- const n = await fetch(f, {
923
+ L("fetching challenge from", a);
924
+ const u = await fetch(a, {
923
925
  headers: {
924
- "x-altcha-spam-filter": k ? "1" : "0"
926
+ "x-altcha-spam-filter": _ ? "1" : "0"
925
927
  }
926
928
  });
927
- if (n.status !== 200)
928
- throw new Error(`Server responded with ${n.status}.`);
929
- const h = n.headers.get("Expires"), C = n.headers.get("X-Altcha-Config");
930
- if (C)
929
+ if (u.status !== 200)
930
+ throw new Error(`Server responded with ${u.status}.`);
931
+ const v = u.headers.get("Expires"), N = u.headers.get("X-Altcha-Config"), j = await u.json(), T = new URLSearchParams((n = j.salt.split("?")) == null ? void 0 : n[1]), W = T.get("expires") || T.get("expire");
932
+ if (W) {
933
+ const x = new Date(+W * 1e3), E = isNaN(x.getTime()) ? 0 : x.getTime() - Date.now();
934
+ E > 0 && ne(E);
935
+ }
936
+ if (N)
931
937
  try {
932
- const p = JSON.parse(C);
933
- p && typeof p == "object" && (p.verifyurl && (p.verifyurl = new URL(p.verifyurl, new URL(f)).toString()), xe(p));
934
- } catch (p) {
935
- $("unable to configure from X-Altcha-Config", p);
938
+ const x = JSON.parse(N);
939
+ x && typeof x == "object" && (x.verifyurl && (x.verifyurl = new URL(x.verifyurl, new URL(a)).toString()), xe(x));
940
+ } catch (x) {
941
+ L("unable to configure from X-Altcha-Config", x);
936
942
  }
937
- if (!m && (h != null && h.length)) {
938
- const p = Date.parse(h);
939
- if (p) {
940
- const S = p - Date.now();
941
- S > 0 && ce(S);
943
+ if (!C && (v != null && v.length)) {
944
+ const x = Date.parse(v);
945
+ if (x) {
946
+ const E = x - Date.now();
947
+ E > 0 && ne(E);
942
948
  }
943
949
  }
944
- return n.json();
950
+ return j;
945
951
  }
946
952
  }
947
953
  function ke() {
948
- f && V && O === v.VERIFIED ? B() : te(v.EXPIRED, o.expired);
954
+ a && X && D === p.VERIFIED ? P() : ie(p.EXPIRED, o.expired);
949
955
  }
950
- async function Ye(n) {
951
- let h = null;
956
+ async function We(n) {
957
+ let u = null;
952
958
  if ("Worker" in window) {
953
959
  try {
954
- h = await Xe(n.challenge, n.salt, n.algorithm, n.maxnumber);
955
- } catch (C) {
956
- $(C);
960
+ u = await Be(n.challenge, n.salt, n.algorithm, n.maxnumber);
961
+ } catch (v) {
962
+ L(v);
957
963
  }
958
- if ((h == null ? void 0 : h.number) !== void 0)
959
- return { data: n, solution: h };
964
+ if ((u == null ? void 0 : u.number) !== void 0)
965
+ return { data: n, solution: u };
960
966
  }
961
967
  return {
962
968
  data: n,
963
- solution: await jt(n.challenge, n.salt, n.algorithm, n.maxnumber || _).promise
969
+ solution: await At(n.challenge, n.salt, n.algorithm, n.maxnumber || w).promise
964
970
  };
965
971
  }
966
- async function Xe(n, h, C, p = _, S = Math.ceil(d)) {
967
- const H = [];
968
- if (S < 1)
972
+ async function Be(n, u, v, N = typeof g == "number" ? g : w, j = Math.ceil(d)) {
973
+ const T = [];
974
+ if (j < 1)
969
975
  throw new Error("Wrong number of workers configured.");
970
- if (S > 16)
976
+ if (j > 16)
971
977
  throw new Error("Too many workers. Max. 16 allowed workers.");
972
- for (let T = 0; T < S; T++)
973
- H.push(new Nt());
974
- const re = Math.ceil(p / S), ne = await Promise.all(H.map((T, ie) => {
975
- const Ce = ie * re;
978
+ for (let E = 0; E < j; E++)
979
+ T.push(new Nt());
980
+ const W = Math.ceil(N / j), x = await Promise.all(T.map((E, le) => {
981
+ const Ce = le * W;
976
982
  return new Promise((rt) => {
977
- T.addEventListener("message", (Le) => {
983
+ E.addEventListener("message", (Le) => {
978
984
  if (Le.data)
979
- for (const Ie of H)
980
- Ie !== T && Ie.postMessage({ type: "abort" });
985
+ for (const Re of T)
986
+ Re !== E && Re.postMessage({ type: "abort" });
981
987
  rt(Le.data);
982
- }), T.postMessage({
988
+ }), E.postMessage({
983
989
  payload: {
984
- alg: C,
990
+ alg: v,
985
991
  challenge: n,
986
- max: Ce + re,
987
- salt: h,
992
+ max: Ce + W,
993
+ salt: u,
988
994
  start: Ce
989
995
  },
990
996
  type: "work"
991
997
  });
992
998
  });
993
999
  }));
994
- for (const T of H)
995
- T.terminate();
996
- return ne.find((T) => !!T) || null;
1000
+ for (const E of T)
1001
+ E.terminate();
1002
+ return x.find((E) => !!E) || null;
997
1003
  }
998
1004
  function Ke() {
999
- [v.UNVERIFIED, v.ERROR, v.EXPIRED].includes(O) ? k && (b == null ? void 0 : b.reportValidity()) === !1 ? t(6, D = !1) : B() : t(6, D = !0);
1005
+ [p.UNVERIFIED, p.ERROR, p.EXPIRED].includes(D) ? _ && (m == null ? void 0 : m.reportValidity()) === !1 ? t(6, F = !1) : P() : t(6, F = !0);
1000
1006
  }
1001
1007
  function Je() {
1002
- O === v.VERIFYING && alert(o.waitAlert);
1008
+ D === p.VERIFYING && alert(o.waitAlert);
1003
1009
  }
1004
- function ce(n) {
1005
- $("expire", n), clearTimeout(se), n < 1 ? ke() : se = setTimeout(ke, n);
1010
+ function ne(n) {
1011
+ L("expire", n), clearTimeout(ce), n < 1 ? ke() : ce = setTimeout(ke, n);
1006
1012
  }
1007
1013
  function ze(n) {
1008
- var C;
1009
- const h = b == null ? void 0 : b.querySelector(typeof n == "string" ? `input[name="${n}"]` : 'input[type="email"]:not([data-no-spamfilter])');
1010
- return ((C = h == null ? void 0 : h.value) == null ? void 0 : C.slice(h.value.indexOf("@"))) || void 0;
1014
+ var v;
1015
+ const u = m == null ? void 0 : m.querySelector(typeof n == "string" ? `input[name="${n}"]` : 'input[type="email"]:not([data-no-spamfilter])');
1016
+ return ((v = u == null ? void 0 : u.value) == null ? void 0 : v.slice(u.value.indexOf("@"))) || void 0;
1011
1017
  }
1012
1018
  function Qe(n) {
1013
1019
  return [
1014
- ...(b == null ? void 0 : b.querySelectorAll(n != null && n.length ? n.map((C) => `input[name="${C}"]`).join(", ") : 'input[type="text"]:not([data-no-spamfilter]), textarea:not([data-no-spamfilter])')) || []
1020
+ ...(m == null ? void 0 : m.querySelectorAll(n != null && n.length ? n.map((v) => `input[name="${v}"]`).join(", ") : 'input[type="text"]:not([data-no-spamfilter]), textarea:not([data-no-spamfilter])')) || []
1015
1021
  ].reduce(
1016
- (C, p) => {
1017
- const S = p.name, H = p.value.trim();
1018
- return S && H && (C[S] = H), C;
1022
+ (v, N) => {
1023
+ const j = N.name, T = N.value.trim();
1024
+ return j && T && (v[j] = T), v;
1019
1025
  },
1020
1026
  {}
1021
1027
  );
1022
1028
  }
1023
1029
  async function qe(n) {
1024
- if (!y)
1030
+ if (!b)
1025
1031
  throw new Error("Attribute verifyurl not set.");
1026
- $("requesting server verification from", y);
1027
- const h = { payload: n };
1028
- if (k) {
1029
- const { email: S, expectedLanguages: H, expectedCountries: re, fields: ne, ipAddress: T, timeZone: ie } = typeof k == "object" ? k : {
1032
+ L("requesting server verification from", b);
1033
+ const u = { payload: n };
1034
+ if (_) {
1035
+ const { email: j, expectedLanguages: T, expectedCountries: W, fields: x, ipAddress: E, timeZone: le } = typeof _ == "object" ? _ : {
1030
1036
  email: void 0,
1031
1037
  expectedCountries: void 0,
1032
1038
  expectedLanguages: void 0,
@@ -1034,107 +1040,107 @@ function Ft(r, e, t) {
1034
1040
  ipAddress: void 0,
1035
1041
  timeZone: void 0
1036
1042
  };
1037
- h.ipAddress = T === !1 ? void 0 : T || "auto", h.email = S === !1 ? void 0 : ze(S), h.fields = ne === !1 ? void 0 : Qe(ne), h.timeZone = ie === !1 ? void 0 : ie || Dt(), h.expectedCountries = re, h.expectedLanguages = H || (be ? [be] : void 0);
1043
+ u.ipAddress = E === !1 ? void 0 : E || "auto", u.email = j === !1 ? void 0 : ze(j), u.fields = x === !1 ? void 0 : Qe(x), u.timeZone = le === !1 ? void 0 : le || Ot(), u.expectedCountries = W, u.expectedLanguages = T || (be ? [be] : void 0);
1038
1044
  }
1039
- const C = await fetch(y, {
1040
- body: JSON.stringify(h),
1045
+ const v = await fetch(b, {
1046
+ body: JSON.stringify(u),
1041
1047
  headers: { "content-type": "application/json" },
1042
1048
  method: "POST"
1043
1049
  });
1044
- if (C.status !== 200)
1045
- throw new Error(`Server responded with ${C.status}.`);
1046
- const p = await C.json();
1047
- if (p != null && p.payload && t(4, W = p.payload), I("serververification", p), a && p.classification === "BAD")
1050
+ if (v.status !== 200)
1051
+ throw new Error(`Server responded with ${v.status}.`);
1052
+ const N = await v.json();
1053
+ if (N != null && N.payload && t(4, Y = N.payload), I("serververification", N), f && N.classification === "BAD")
1048
1054
  throw new Error("SpamFilter returned negative classification.");
1049
1055
  }
1050
1056
  function xe(n) {
1051
- n.auto !== void 0 && (t(0, s = n.auto), s === "onload" && B()), n.expire !== void 0 && (ce(n.expire), t(14, m = n.expire)), n.challenge && (_e(n.challenge), i = n.challenge), n.challengeurl !== void 0 && t(12, f = n.challengeurl), n.debug !== void 0 && t(13, R = !!n.debug), n.hidefooter !== void 0 && t(1, j = !!n.hidefooter), n.hidelogo !== void 0 && t(2, Z = !!n.hidelogo), n.maxnumber !== void 0 && t(15, _ = +n.maxnumber), n.mockerror !== void 0 && t(16, F = !!n.mockerror), n.name !== void 0 && t(3, G = n.name), n.refetchonexpire !== void 0 && t(17, V = !!n.refetchonexpire), n.spamfilter !== void 0 && t(18, k = typeof n.spamfilter == "object" ? n.spamfilter : !!n.spamfilter), n.strings && t(28, l = n.strings), n.test !== void 0 && t(19, g = typeof n.test == "number" ? n.test : !!n.test), n.verifyurl !== void 0 && t(20, y = n.verifyurl), n.workers !== void 0 && t(21, d = +n.workers);
1057
+ n.auto !== void 0 && (t(0, s = n.auto), s === "onload" && P()), n.expire !== void 0 && (ne(n.expire), t(14, C = n.expire)), n.challenge && (_e(n.challenge), i = n.challenge), n.challengeurl !== void 0 && t(12, a = n.challengeurl), n.debug !== void 0 && t(13, A = !!n.debug), n.hidefooter !== void 0 && t(1, V = !!n.hidefooter), n.hidelogo !== void 0 && t(2, G = !!n.hidelogo), n.maxnumber !== void 0 && t(15, w = +n.maxnumber), n.mockerror !== void 0 && t(16, H = !!n.mockerror), n.name !== void 0 && t(3, U = n.name), n.refetchonexpire !== void 0 && t(17, X = !!n.refetchonexpire), n.spamfilter !== void 0 && t(18, _ = typeof n.spamfilter == "object" ? n.spamfilter : !!n.spamfilter), n.strings && t(28, l = n.strings), n.test !== void 0 && t(19, g = typeof n.test == "number" ? n.test : !!n.test), n.verifyurl !== void 0 && t(20, b = n.verifyurl), n.workers !== void 0 && t(21, d = +n.workers);
1052
1058
  }
1053
- function te(n = v.UNVERIFIED, h = null) {
1054
- clearTimeout(se), t(6, D = !1), t(8, oe = h), t(4, W = null), t(5, O = n);
1059
+ function ie(n = p.UNVERIFIED, u = null) {
1060
+ clearTimeout(ce), t(6, F = !1), t(8, se = u), t(4, Y = null), t(5, D = n);
1055
1061
  }
1056
- async function B() {
1057
- return te(v.VERIFYING), Ue().then((n) => (_e(n), $("challenge", n), Ye(n))).then(({ data: n, solution: h }) => {
1058
- if ($("solution", h), (h == null ? void 0 : h.number) !== void 0) {
1059
- if (y)
1060
- return qe(we(n, h));
1061
- t(4, W = we(n, h)), $("payload", W);
1062
+ async function P() {
1063
+ return ie(p.VERIFYING), Pe().then((n) => (_e(n), L("challenge", n), We(n))).then(({ data: n, solution: u }) => {
1064
+ if (L("solution", u), (u == null ? void 0 : u.number) !== void 0) {
1065
+ if (b)
1066
+ return qe(we(n, u));
1067
+ t(4, Y = we(n, u)), L("payload", Y);
1062
1068
  } else
1063
- throw $("Unable to find a solution. Ensure that the 'maxnumber' attribute is greater than the randomly generated number."), new Error("Unexpected result returned.");
1069
+ throw L("Unable to find a solution. Ensure that the 'maxnumber' attribute is greater than the randomly generated number."), new Error("Unexpected result returned.");
1064
1070
  }).then(() => {
1065
1071
  pt().then(() => {
1066
- t(5, O = v.VERIFIED), t(6, D = !0), $("verified"), I("verified", { payload: W });
1072
+ t(5, D = p.VERIFIED), t(6, F = !0), L("verified"), I("verified", { payload: Y });
1067
1073
  });
1068
1074
  }).catch((n) => {
1069
- $(n), t(5, O = v.ERROR), t(6, D = !1), t(8, oe = n.message);
1075
+ L(n), t(5, D = p.ERROR), t(6, F = !1), t(8, se = n.message);
1070
1076
  });
1071
1077
  }
1072
1078
  function et() {
1073
- D = this.checked, t(6, D);
1079
+ F = this.checked, t(6, F);
1074
1080
  }
1075
1081
  function tt(n) {
1076
1082
  ue[n ? "unshift" : "push"](() => {
1077
- ee = n, t(7, ee);
1083
+ re = n, t(7, re);
1078
1084
  });
1079
1085
  }
1080
1086
  return r.$$set = (n) => {
1081
- "auto" in n && t(0, s = n.auto), "blockspam" in n && t(22, a = n.blockspam), "challengeurl" in n && t(12, f = n.challengeurl), "challengejson" in n && t(23, u = n.challengejson), "debug" in n && t(13, R = n.debug), "expire" in n && t(14, m = n.expire), "hidefooter" in n && t(1, j = n.hidefooter), "hidelogo" in n && t(2, Z = n.hidelogo), "name" in n && t(3, G = n.name), "maxnumber" in n && t(15, _ = n.maxnumber), "mockerror" in n && t(16, F = n.mockerror), "refetchonexpire" in n && t(17, V = n.refetchonexpire), "spamfilter" in n && t(18, k = n.spamfilter), "strings" in n && t(24, x = n.strings), "test" in n && t(19, g = n.test), "verifyurl" in n && t(20, y = n.verifyurl), "workers" in n && t(21, d = n.workers);
1087
+ "auto" in n && t(0, s = n.auto), "blockspam" in n && t(22, f = n.blockspam), "challengeurl" in n && t(12, a = n.challengeurl), "challengejson" in n && t(23, h = n.challengejson), "debug" in n && t(13, A = n.debug), "expire" in n && t(14, C = n.expire), "hidefooter" in n && t(1, V = n.hidefooter), "hidelogo" in n && t(2, G = n.hidelogo), "name" in n && t(3, U = n.name), "maxnumber" in n && t(15, w = n.maxnumber), "mockerror" in n && t(16, H = n.mockerror), "refetchonexpire" in n && t(17, X = n.refetchonexpire), "spamfilter" in n && t(18, _ = n.spamfilter), "strings" in n && t(24, k = n.strings), "test" in n && t(19, g = n.test), "verifyurl" in n && t(20, b = n.verifyurl), "workers" in n && t(21, d = n.workers);
1082
1088
  }, r.$$.update = () => {
1083
1089
  r.$$.dirty[0] & /*challengejson*/
1084
- 8388608 && (i = u ? Ge(u) : void 0), r.$$.dirty[0] & /*strings*/
1085
- 16777216 && t(28, l = x ? Ge(x) : {}), r.$$.dirty[0] & /*parsedStrings*/
1090
+ 8388608 && (i = h ? Ve(h) : void 0), r.$$.dirty[0] & /*strings*/
1091
+ 16777216 && t(28, l = k ? Ve(k) : {}), r.$$.dirty[0] & /*parsedStrings*/
1086
1092
  268435456 && t(9, o = {
1087
1093
  error: "Verification failed. Try again later.",
1088
1094
  expired: "Verification expired. Try again.",
1089
- footer: `Protected by <a href="${Be}" target="_blank">ALTCHA</a>`,
1095
+ footer: `Protected by <a href="${Ye}" target="_blank">ALTCHA</a>`,
1090
1096
  label: "I'm not a robot",
1091
1097
  verified: "Verified",
1092
1098
  verifying: "Verifying...",
1093
1099
  waitAlert: "Verifying... please wait.",
1094
1100
  ...l
1095
1101
  }), r.$$.dirty[0] & /*payload, state*/
1096
- 48 && I("statechange", { payload: W, state: O });
1102
+ 48 && I("statechange", { payload: Y, state: D });
1097
1103
  }, [
1098
1104
  s,
1099
- j,
1100
- Z,
1105
+ V,
1101
1106
  G,
1102
- W,
1103
- O,
1107
+ U,
1108
+ Y,
1104
1109
  D,
1105
- ee,
1106
- oe,
1110
+ F,
1111
+ re,
1112
+ se,
1107
1113
  o,
1108
1114
  Ke,
1109
1115
  Je,
1110
- f,
1111
- R,
1112
- m,
1116
+ a,
1117
+ A,
1118
+ C,
1119
+ w,
1120
+ H,
1121
+ X,
1113
1122
  _,
1114
- F,
1115
- V,
1116
- k,
1117
1123
  g,
1118
- y,
1124
+ b,
1119
1125
  d,
1120
- a,
1121
- u,
1122
- x,
1126
+ f,
1127
+ h,
1128
+ k,
1123
1129
  xe,
1124
- te,
1125
- B,
1130
+ ie,
1131
+ P,
1126
1132
  l,
1127
1133
  et,
1128
1134
  tt
1129
1135
  ];
1130
1136
  }
1131
- class Wt extends Lt {
1137
+ class Ht extends Lt {
1132
1138
  constructor(e) {
1133
1139
  super(), $t(
1134
1140
  this,
1135
1141
  e,
1136
1142
  Ft,
1137
- Pt,
1143
+ Dt,
1138
1144
  lt,
1139
1145
  {
1140
1146
  auto: 0,
@@ -1158,7 +1164,7 @@ class Wt extends Lt {
1158
1164
  reset: 26,
1159
1165
  verify: 27
1160
1166
  },
1161
- Mt,
1167
+ Tt,
1162
1168
  [-1, -1]
1163
1169
  );
1164
1170
  }
@@ -1166,103 +1172,103 @@ class Wt extends Lt {
1166
1172
  return this.$$.ctx[0];
1167
1173
  }
1168
1174
  set auto(e) {
1169
- this.$$set({ auto: e }), E();
1175
+ this.$$set({ auto: e }), $();
1170
1176
  }
1171
1177
  get blockspam() {
1172
1178
  return this.$$.ctx[22];
1173
1179
  }
1174
1180
  set blockspam(e) {
1175
- this.$$set({ blockspam: e }), E();
1181
+ this.$$set({ blockspam: e }), $();
1176
1182
  }
1177
1183
  get challengeurl() {
1178
1184
  return this.$$.ctx[12];
1179
1185
  }
1180
1186
  set challengeurl(e) {
1181
- this.$$set({ challengeurl: e }), E();
1187
+ this.$$set({ challengeurl: e }), $();
1182
1188
  }
1183
1189
  get challengejson() {
1184
1190
  return this.$$.ctx[23];
1185
1191
  }
1186
1192
  set challengejson(e) {
1187
- this.$$set({ challengejson: e }), E();
1193
+ this.$$set({ challengejson: e }), $();
1188
1194
  }
1189
1195
  get debug() {
1190
1196
  return this.$$.ctx[13];
1191
1197
  }
1192
1198
  set debug(e) {
1193
- this.$$set({ debug: e }), E();
1199
+ this.$$set({ debug: e }), $();
1194
1200
  }
1195
1201
  get expire() {
1196
1202
  return this.$$.ctx[14];
1197
1203
  }
1198
1204
  set expire(e) {
1199
- this.$$set({ expire: e }), E();
1205
+ this.$$set({ expire: e }), $();
1200
1206
  }
1201
1207
  get hidefooter() {
1202
1208
  return this.$$.ctx[1];
1203
1209
  }
1204
1210
  set hidefooter(e) {
1205
- this.$$set({ hidefooter: e }), E();
1211
+ this.$$set({ hidefooter: e }), $();
1206
1212
  }
1207
1213
  get hidelogo() {
1208
1214
  return this.$$.ctx[2];
1209
1215
  }
1210
1216
  set hidelogo(e) {
1211
- this.$$set({ hidelogo: e }), E();
1217
+ this.$$set({ hidelogo: e }), $();
1212
1218
  }
1213
1219
  get name() {
1214
1220
  return this.$$.ctx[3];
1215
1221
  }
1216
1222
  set name(e) {
1217
- this.$$set({ name: e }), E();
1223
+ this.$$set({ name: e }), $();
1218
1224
  }
1219
1225
  get maxnumber() {
1220
1226
  return this.$$.ctx[15];
1221
1227
  }
1222
1228
  set maxnumber(e) {
1223
- this.$$set({ maxnumber: e }), E();
1229
+ this.$$set({ maxnumber: e }), $();
1224
1230
  }
1225
1231
  get mockerror() {
1226
1232
  return this.$$.ctx[16];
1227
1233
  }
1228
1234
  set mockerror(e) {
1229
- this.$$set({ mockerror: e }), E();
1235
+ this.$$set({ mockerror: e }), $();
1230
1236
  }
1231
1237
  get refetchonexpire() {
1232
1238
  return this.$$.ctx[17];
1233
1239
  }
1234
1240
  set refetchonexpire(e) {
1235
- this.$$set({ refetchonexpire: e }), E();
1241
+ this.$$set({ refetchonexpire: e }), $();
1236
1242
  }
1237
1243
  get spamfilter() {
1238
1244
  return this.$$.ctx[18];
1239
1245
  }
1240
1246
  set spamfilter(e) {
1241
- this.$$set({ spamfilter: e }), E();
1247
+ this.$$set({ spamfilter: e }), $();
1242
1248
  }
1243
1249
  get strings() {
1244
1250
  return this.$$.ctx[24];
1245
1251
  }
1246
1252
  set strings(e) {
1247
- this.$$set({ strings: e }), E();
1253
+ this.$$set({ strings: e }), $();
1248
1254
  }
1249
1255
  get test() {
1250
1256
  return this.$$.ctx[19];
1251
1257
  }
1252
1258
  set test(e) {
1253
- this.$$set({ test: e }), E();
1259
+ this.$$set({ test: e }), $();
1254
1260
  }
1255
1261
  get verifyurl() {
1256
1262
  return this.$$.ctx[20];
1257
1263
  }
1258
1264
  set verifyurl(e) {
1259
- this.$$set({ verifyurl: e }), E();
1265
+ this.$$set({ verifyurl: e }), $();
1260
1266
  }
1261
1267
  get workers() {
1262
1268
  return this.$$.ctx[21];
1263
1269
  }
1264
1270
  set workers(e) {
1265
- this.$$set({ workers: e }), E();
1271
+ this.$$set({ workers: e }), $();
1266
1272
  }
1267
1273
  get configure() {
1268
1274
  return this.$$.ctx[25];
@@ -1274,7 +1280,7 @@ class Wt extends Lt {
1274
1280
  return this.$$.ctx[27];
1275
1281
  }
1276
1282
  }
1277
- customElements.define("altcha-widget", Ct(Wt, { auto: {}, blockspam: {}, challengeurl: {}, challengejson: {}, debug: { type: "Boolean" }, expire: {}, hidefooter: { type: "Boolean" }, hidelogo: { type: "Boolean" }, name: {}, maxnumber: {}, mockerror: { type: "Boolean" }, refetchonexpire: { type: "Boolean" }, spamfilter: { type: "Boolean" }, strings: {}, test: { type: "Boolean" }, verifyurl: {}, workers: {} }, [], ["configure", "reset", "verify"], !1));
1283
+ customElements.define("altcha-widget", Ct(Ht, { auto: {}, blockspam: {}, challengeurl: {}, challengejson: {}, debug: { type: "Boolean" }, expire: {}, hidefooter: { type: "Boolean" }, hidelogo: { type: "Boolean" }, name: {}, maxnumber: {}, mockerror: { type: "Boolean" }, refetchonexpire: { type: "Boolean" }, spamfilter: { type: "Boolean" }, strings: {}, test: { type: "Boolean" }, verifyurl: {}, workers: {} }, [], ["configure", "reset", "verify"], !1));
1278
1284
  export {
1279
- Wt as Altcha
1285
+ Ht as Altcha
1280
1286
  };