altcha 0.6.1 → 0.6.2

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,11 +1,11 @@
1
1
  var yt = Object.defineProperty;
2
2
  var pt = (r, e, t) => e in r ? yt(r, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : r[e] = t;
3
3
  var G = (r, e, t) => pt(r, typeof e != "symbol" ? e + "" : e, t);
4
- const Qe = "KGZ1bmN0aW9uKCl7InVzZSBzdHJpY3QiO2NvbnN0IGY9bmV3IFRleHRFbmNvZGVyO2Z1bmN0aW9uIGQoZSl7cmV0dXJuWy4uLm5ldyBVaW50OEFycmF5KGUpXS5tYXAodD0+dC50b1N0cmluZygxNikucGFkU3RhcnQoMiwiMCIpKS5qb2luKCIiKX1hc3luYyBmdW5jdGlvbiBwKGUsdCxvKXtyZXR1cm4gZChhd2FpdCBjcnlwdG8uc3VidGxlLmRpZ2VzdChvLnRvVXBwZXJDYXNlKCksZi5lbmNvZGUoZSt0KSkpfWZ1bmN0aW9uIGcoZSx0LG89IlNIQS0yNTYiLGw9MWU2LGM9MCl7Y29uc3QgYT1uZXcgQWJvcnRDb250cm9sbGVyLGk9RGF0ZS5ub3coKTtyZXR1cm57cHJvbWlzZTooYXN5bmMoKT0+e2ZvcihsZXQgbj1jO248PWw7bis9MSl7aWYoYS5zaWduYWwuYWJvcnRlZClyZXR1cm4gbnVsbDtpZihhd2FpdCBwKHQsbixvKT09PWUpcmV0dXJue251bWJlcjpuLHRvb2s6RGF0ZS5ub3coKS1pfX1yZXR1cm4gbnVsbH0pKCksY29udHJvbGxlcjphfX1sZXQgcjtvbm1lc3NhZ2U9YXN5bmMgZT0+e2NvbnN0e3R5cGU6dCxwYXlsb2FkOm99PWUuZGF0YTtpZih0PT09ImFib3J0IilyPT1udWxsfHxyLmFib3J0KCkscj12b2lkIDA7ZWxzZSBpZih0PT09IndvcmsiKXtjb25zdHthbGc6bCxjaGFsbGVuZ2U6YyxtYXg6YSxzYWx0Omksc3RhcnQ6dX09b3x8e30sbj1nKGMsaSxsLGEsdSk7cj1uLmNvbnRyb2xsZXIsbi5wcm9taXNlLnRoZW4ocz0+e3NlbGYucG9zdE1lc3NhZ2UocyYmey4uLnMsd29ya2VyOiEwfSl9KX19fSkoKTsK", _t = (r) => Uint8Array.from(atob(r), (e) => e.charCodeAt(0)), Ge = typeof window < "u" && window.Blob && new Blob([_t(Qe)], { type: "text/javascript;charset=utf-8" });
4
+ const et = "KGZ1bmN0aW9uKCl7InVzZSBzdHJpY3QiO2NvbnN0IGY9bmV3IFRleHRFbmNvZGVyO2Z1bmN0aW9uIGQoZSl7cmV0dXJuWy4uLm5ldyBVaW50OEFycmF5KGUpXS5tYXAodD0+dC50b1N0cmluZygxNikucGFkU3RhcnQoMiwiMCIpKS5qb2luKCIiKX1hc3luYyBmdW5jdGlvbiBwKGUsdCxvKXtyZXR1cm4gZChhd2FpdCBjcnlwdG8uc3VidGxlLmRpZ2VzdChvLnRvVXBwZXJDYXNlKCksZi5lbmNvZGUoZSt0KSkpfWZ1bmN0aW9uIGcoZSx0LG89IlNIQS0yNTYiLGw9MWU2LGM9MCl7Y29uc3QgYT1uZXcgQWJvcnRDb250cm9sbGVyLGk9RGF0ZS5ub3coKTtyZXR1cm57cHJvbWlzZTooYXN5bmMoKT0+e2ZvcihsZXQgbj1jO248PWw7bis9MSl7aWYoYS5zaWduYWwuYWJvcnRlZClyZXR1cm4gbnVsbDtpZihhd2FpdCBwKHQsbixvKT09PWUpcmV0dXJue251bWJlcjpuLHRvb2s6RGF0ZS5ub3coKS1pfX1yZXR1cm4gbnVsbH0pKCksY29udHJvbGxlcjphfX1sZXQgcjtvbm1lc3NhZ2U9YXN5bmMgZT0+e2NvbnN0e3R5cGU6dCxwYXlsb2FkOm99PWUuZGF0YTtpZih0PT09ImFib3J0IilyPT1udWxsfHxyLmFib3J0KCkscj12b2lkIDA7ZWxzZSBpZih0PT09IndvcmsiKXtjb25zdHthbGc6bCxjaGFsbGVuZ2U6YyxtYXg6YSxzYWx0Omksc3RhcnQ6dX09b3x8e30sbj1nKGMsaSxsLGEsdSk7cj1uLmNvbnRyb2xsZXIsbi5wcm9taXNlLnRoZW4ocz0+e3NlbGYucG9zdE1lc3NhZ2UocyYmey4uLnMsd29ya2VyOiEwfSl9KX19fSkoKTsK", _t = (r) => Uint8Array.from(atob(r), (e) => e.charCodeAt(0)), We = typeof window < "u" && window.Blob && new Blob([_t(et)], { type: "text/javascript;charset=utf-8" });
5
5
  function kt(r) {
6
6
  let e;
7
7
  try {
8
- if (e = Ge && (window.URL || window.webkitURL).createObjectURL(Ge), !e) throw "";
8
+ if (e = We && (window.URL || window.webkitURL).createObjectURL(We), !e) throw "";
9
9
  const t = new Worker(e, {
10
10
  name: r == null ? void 0 : r.name
11
11
  });
@@ -14,7 +14,7 @@ function kt(r) {
14
14
  }), t;
15
15
  } catch {
16
16
  return new Worker(
17
- "data:text/javascript;base64," + Qe,
17
+ "data:text/javascript;base64," + et,
18
18
  {
19
19
  name: r == null ? void 0 : r.name
20
20
  }
@@ -25,16 +25,16 @@ function kt(r) {
25
25
  }
26
26
  function ne() {
27
27
  }
28
- function et(r) {
28
+ function tt(r) {
29
29
  return r();
30
30
  }
31
- function We() {
31
+ function Xe() {
32
32
  return /* @__PURE__ */ Object.create(null);
33
33
  }
34
- function se(r) {
35
- r.forEach(et);
34
+ function ae(r) {
35
+ r.forEach(tt);
36
36
  }
37
- function tt(r) {
37
+ function rt(r) {
38
38
  return typeof r == "function";
39
39
  }
40
40
  function xt(r, e) {
@@ -72,7 +72,7 @@ function Rt(r, e) {
72
72
  function $(r, e, t) {
73
73
  r.insertBefore(e, t || null);
74
74
  }
75
- function Z(r) {
75
+ function T(r) {
76
76
  r.parentNode && r.parentNode.removeChild(r);
77
77
  }
78
78
  function A(r) {
@@ -87,7 +87,7 @@ function zt(r) {
87
87
  function Y() {
88
88
  return zt(" ");
89
89
  }
90
- function ve(r, e, t, i) {
90
+ function ke(r, e, t, i) {
91
91
  return r.addEventListener(e, t, i), () => r.removeEventListener(e, t, i);
92
92
  }
93
93
  function c(r, e, t) {
@@ -96,7 +96,7 @@ function c(r, e, t) {
96
96
  function It(r) {
97
97
  return Array.from(r.childNodes);
98
98
  }
99
- function Xe(r, e, t) {
99
+ function Be(r, e, t) {
100
100
  r.classList.toggle(e, !!t);
101
101
  }
102
102
  function At(r, e, { bubbles: t = !1, cancelable: i = !1 } = {}) {
@@ -111,22 +111,22 @@ function Nt(r) {
111
111
  }
112
112
  ), e;
113
113
  }
114
- let le;
115
- function oe(r) {
116
- le = r;
114
+ let ce;
115
+ function se(r) {
116
+ ce = r;
117
117
  }
118
- function ke() {
119
- if (!le) throw new Error("Function called outside component initialization");
120
- return le;
118
+ function Le() {
119
+ if (!ce) throw new Error("Function called outside component initialization");
120
+ return ce;
121
121
  }
122
122
  function St(r) {
123
- ke().$$.on_mount.push(r);
123
+ Le().$$.on_mount.push(r);
124
124
  }
125
125
  function jt(r) {
126
- ke().$$.on_destroy.push(r);
126
+ Le().$$.on_destroy.push(r);
127
127
  }
128
128
  function Tt() {
129
- const r = ke();
129
+ const r = Le();
130
130
  return (e, t, { cancelable: i = !1 } = {}) => {
131
131
  const o = r.$$.callbacks[e];
132
132
  if (o) {
@@ -143,50 +143,50 @@ function Tt() {
143
143
  return !0;
144
144
  };
145
145
  }
146
- const te = [], he = [];
146
+ const te = [], be = [];
147
147
  let re = [];
148
- const Be = [], rt = /* @__PURE__ */ Promise.resolve();
149
- let pe = !1;
150
- function nt() {
151
- pe || (pe = !0, rt.then(w));
148
+ const He = [], nt = /* @__PURE__ */ Promise.resolve();
149
+ let Ee = !1;
150
+ function it() {
151
+ Ee || (Ee = !0, nt.then(v));
152
152
  }
153
153
  function Zt() {
154
- return nt(), rt;
154
+ return it(), nt;
155
155
  }
156
- function _e(r) {
156
+ function Ce(r) {
157
157
  re.push(r);
158
158
  }
159
- const ye = /* @__PURE__ */ new Set();
159
+ const xe = /* @__PURE__ */ new Set();
160
160
  let ee = 0;
161
- function w() {
161
+ function v() {
162
162
  if (ee !== 0)
163
163
  return;
164
- const r = le;
164
+ const r = ce;
165
165
  do {
166
166
  try {
167
167
  for (; ee < te.length; ) {
168
168
  const e = te[ee];
169
- ee++, oe(e), Mt(e.$$);
169
+ ee++, se(e), Mt(e.$$);
170
170
  }
171
171
  } catch (e) {
172
172
  throw te.length = 0, ee = 0, e;
173
173
  }
174
- for (oe(null), te.length = 0, ee = 0; he.length; ) he.pop()();
174
+ for (se(null), te.length = 0, ee = 0; be.length; ) be.pop()();
175
175
  for (let e = 0; e < re.length; e += 1) {
176
176
  const t = re[e];
177
- ye.has(t) || (ye.add(t), t());
177
+ xe.has(t) || (xe.add(t), t());
178
178
  }
179
179
  re.length = 0;
180
180
  } while (te.length);
181
- for (; Be.length; )
182
- Be.pop()();
183
- pe = !1, ye.clear(), oe(r);
181
+ for (; He.length; )
182
+ He.pop()();
183
+ Ee = !1, xe.clear(), se(r);
184
184
  }
185
185
  function Mt(r) {
186
186
  if (r.fragment !== null) {
187
- r.update(), se(r.before_update);
187
+ r.update(), ae(r.before_update);
188
188
  const e = r.dirty;
189
- r.dirty = [-1], r.fragment && r.fragment.p(r.ctx, e), r.after_update.forEach(_e);
189
+ r.dirty = [-1], r.fragment && r.fragment.p(r.ctx, e), r.after_update.forEach(Ce);
190
190
  }
191
191
  }
192
192
  function Vt(r) {
@@ -199,21 +199,21 @@ function Dt(r, e) {
199
199
  }
200
200
  function Ut(r, e, t) {
201
201
  const { fragment: i, after_update: o } = r.$$;
202
- i && i.m(e, t), _e(() => {
203
- const l = r.$$.on_mount.map(et).filter(tt);
204
- r.$$.on_destroy ? r.$$.on_destroy.push(...l) : se(l), r.$$.on_mount = [];
205
- }), o.forEach(_e);
202
+ i && i.m(e, t), Ce(() => {
203
+ const l = r.$$.on_mount.map(tt).filter(rt);
204
+ r.$$.on_destroy ? r.$$.on_destroy.push(...l) : ae(l), r.$$.on_mount = [];
205
+ }), o.forEach(Ce);
206
206
  }
207
207
  function Ft(r, e) {
208
208
  const t = r.$$;
209
- t.fragment !== null && (Vt(t.after_update), se(t.on_destroy), t.fragment && t.fragment.d(e), t.on_destroy = t.fragment = null, t.ctx = []);
209
+ t.fragment !== null && (Vt(t.after_update), ae(t.on_destroy), t.fragment && t.fragment.d(e), t.on_destroy = t.fragment = null, t.ctx = []);
210
210
  }
211
211
  function Gt(r, e) {
212
- r.$$.dirty[0] === -1 && (te.push(r), nt(), r.$$.dirty.fill(0)), r.$$.dirty[e / 31 | 0] |= 1 << e % 31;
212
+ r.$$.dirty[0] === -1 && (te.push(r), it(), r.$$.dirty.fill(0)), r.$$.dirty[e / 31 | 0] |= 1 << e % 31;
213
213
  }
214
214
  function Wt(r, e, t, i, o, l, s = null, u = [-1]) {
215
- const a = le;
216
- oe(r);
215
+ const f = ce;
216
+ se(r);
217
217
  const d = r.$$ = {
218
218
  fragment: null,
219
219
  ctx: [],
@@ -221,37 +221,37 @@ function Wt(r, e, t, i, o, l, s = null, u = [-1]) {
221
221
  props: l,
222
222
  update: ne,
223
223
  not_equal: o,
224
- bound: We(),
224
+ bound: Xe(),
225
225
  // lifecycle
226
226
  on_mount: [],
227
227
  on_destroy: [],
228
228
  on_disconnect: [],
229
229
  before_update: [],
230
230
  after_update: [],
231
- context: new Map(e.context || (a ? a.$$.context : [])),
231
+ context: new Map(e.context || (f ? f.$$.context : [])),
232
232
  // everything else
233
- callbacks: We(),
233
+ callbacks: Xe(),
234
234
  dirty: u,
235
235
  skip_bound: !1,
236
- root: e.target || a.$$.root
236
+ root: e.target || f.$$.root
237
237
  };
238
238
  s && s(d.root);
239
239
  let U = !1;
240
240
  if (d.ctx = t ? t(r, e.props || {}, (S, D, ...k) => {
241
241
  const F = k.length ? k[0] : D;
242
242
  return d.ctx && o(d.ctx[S], d.ctx[S] = F) && (!d.skip_bound && d.bound[S] && d.bound[S](F), U && Gt(r, S)), D;
243
- }) : [], d.update(), U = !0, se(d.before_update), d.fragment = i ? i(d.ctx) : !1, e.target) {
243
+ }) : [], d.update(), U = !0, ae(d.before_update), d.fragment = i ? i(d.ctx) : !1, e.target) {
244
244
  if (e.hydrate) {
245
245
  const S = It(e.target);
246
- d.fragment && d.fragment.l(S), S.forEach(Z);
246
+ d.fragment && d.fragment.l(S), S.forEach(T);
247
247
  } else
248
248
  d.fragment && d.fragment.c();
249
- e.intro && Dt(r.$$.fragment), Ut(r, e.target, e.anchor), w();
249
+ e.intro && Dt(r.$$.fragment), Ut(r, e.target, e.anchor), v();
250
250
  }
251
- oe(a);
251
+ se(f);
252
252
  }
253
- let it;
254
- typeof HTMLElement == "function" && (it = class extends HTMLElement {
253
+ let ot;
254
+ typeof HTMLElement == "function" && (ot = class extends HTMLElement {
255
255
  constructor(e, t, i) {
256
256
  super();
257
257
  /** The Svelte component constructor */
@@ -304,7 +304,7 @@ typeof HTMLElement == "function" && (it = class extends HTMLElement {
304
304
  $(d, s, U);
305
305
  },
306
306
  d: function(d) {
307
- d && Z(s);
307
+ d && T(s);
308
308
  }
309
309
  };
310
310
  };
@@ -316,7 +316,7 @@ typeof HTMLElement == "function" && (it = class extends HTMLElement {
316
316
  l in i && (t[l] = [e(l)]);
317
317
  for (const l of this.attributes) {
318
318
  const s = this.$$g_p(l.name);
319
- s in this.$$d || (this.$$d[s] = de(s, l.value, this.$$p_d, "toProp"));
319
+ s in this.$$d || (this.$$d[s] = me(s, l.value, this.$$p_d, "toProp"));
320
320
  }
321
321
  for (const l in this.$$p_d)
322
322
  !(l in this.$$d) && this[l] !== void 0 && (this.$$d[l] = this[l], delete this[l]);
@@ -334,7 +334,7 @@ typeof HTMLElement == "function" && (it = class extends HTMLElement {
334
334
  this.$$r = !0;
335
335
  for (const l in this.$$p_d)
336
336
  if (this.$$d[l] = this.$$c.$$.ctx[this.$$c.$$.props[l]], this.$$p_d[l].reflect) {
337
- const s = de(
337
+ const s = me(
338
338
  l,
339
339
  this.$$d[l],
340
340
  this.$$p_d,
@@ -357,7 +357,7 @@ typeof HTMLElement == "function" && (it = class extends HTMLElement {
357
357
  // and setting attributes through setAttribute etc, this is helpful
358
358
  attributeChangedCallback(e, t, i) {
359
359
  var o;
360
- this.$$r || (e = this.$$g_p(e), this.$$d[e] = de(e, i, this.$$p_d, "toProp"), (o = this.$$c) == null || o.$set({ [e]: this.$$d[e] }));
360
+ this.$$r || (e = this.$$g_p(e), this.$$d[e] = me(e, i, this.$$p_d, "toProp"), (o = this.$$c) == null || o.$set({ [e]: this.$$d[e] }));
361
361
  }
362
362
  disconnectedCallback() {
363
363
  this.$$cn = !1, Promise.resolve().then(() => {
@@ -370,7 +370,7 @@ typeof HTMLElement == "function" && (it = class extends HTMLElement {
370
370
  ) || e;
371
371
  }
372
372
  });
373
- function de(r, e, t, i) {
373
+ function me(r, e, t, i) {
374
374
  var l;
375
375
  const o = (l = t[r]) == null ? void 0 : l.type;
376
376
  if (e = o === "Boolean" && typeof e != "boolean" ? e != null : e, !i || !t[r])
@@ -401,7 +401,7 @@ function de(r, e, t, i) {
401
401
  }
402
402
  }
403
403
  function Xt(r, e, t, i, o, l) {
404
- let s = class extends it {
404
+ let s = class extends ot {
405
405
  constructor() {
406
406
  super(r, t, o), this.$$p_d = e;
407
407
  }
@@ -416,16 +416,16 @@ function Xt(r, e, t, i, o, l) {
416
416
  get() {
417
417
  return this.$$c && u in this.$$c ? this.$$c[u] : this.$$d[u];
418
418
  },
419
- set(a) {
419
+ set(f) {
420
420
  var d;
421
- a = de(u, a, e), this.$$d[u] = a, (d = this.$$c) == null || d.$set({ [u]: a });
421
+ f = me(u, f, e), this.$$d[u] = f, (d = this.$$c) == null || d.$set({ [u]: f });
422
422
  }
423
423
  });
424
424
  }), i.forEach((u) => {
425
425
  Object.defineProperty(s.prototype, u, {
426
426
  get() {
427
- var a;
428
- return (a = this.$$c) == null ? void 0 : a[u];
427
+ var f;
428
+ return (f = this.$$c) == null ? void 0 : f[u];
429
429
  }
430
430
  });
431
431
  }), l && (s = l(s)), r.element = /** @type {any} */
@@ -461,7 +461,7 @@ class Bt {
461
461
  * @returns {() => void}
462
462
  */
463
463
  $on(e, t) {
464
- if (!tt(t))
464
+ if (!rt(t))
465
465
  return ne;
466
466
  const i = this.$$.callbacks[e] || (this.$$.callbacks[e] = []);
467
467
  return i.push(t), () => {
@@ -486,7 +486,7 @@ function Yt(r) {
486
486
  async function Pt(r, e = "SHA-256", t = 1e5) {
487
487
  const i = Date.now().toString(16);
488
488
  r || (r = Math.round(Math.random() * t));
489
- const o = await ot(i, r, e);
489
+ const o = await lt(i, r, e);
490
490
  return {
491
491
  algorithm: e,
492
492
  challenge: o,
@@ -494,7 +494,7 @@ async function Pt(r, e = "SHA-256", t = 1e5) {
494
494
  signature: ""
495
495
  };
496
496
  }
497
- async function ot(r, e, t) {
497
+ async function lt(r, e, t) {
498
498
  return Yt(
499
499
  await crypto.subtle.digest(
500
500
  t.toUpperCase(),
@@ -506,12 +506,12 @@ function Kt(r, e, t = "SHA-256", i = 1e6, o = 0) {
506
506
  const l = new AbortController(), s = Date.now();
507
507
  return {
508
508
  promise: (async () => {
509
- for (let a = o; a <= i; a += 1) {
509
+ for (let f = o; f <= i; f += 1) {
510
510
  if (l.signal.aborted)
511
511
  return null;
512
- if (await ot(e, a, t) === r)
512
+ if (await lt(e, f, t) === r)
513
513
  return {
514
- number: a,
514
+ number: f,
515
515
  took: Date.now() - s
516
516
  };
517
517
  }
@@ -524,7 +524,7 @@ var b = /* @__PURE__ */ ((r) => (r.ERROR = "error", r.VERIFIED = "verified", r.V
524
524
  function Jt(r) {
525
525
  Ct(r, "svelte-ddsc3z", '.altcha.svelte-ddsc3z.svelte-ddsc3z{background:var(--altcha-color-base, transparent);border:var(--altcha-border-width, 1px) solid 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);position:relative;text-align:left}.altcha.svelte-ddsc3z.svelte-ddsc3z:focus-within{border-color:var(--altcha-color-border-focus, currentColor)}.altcha[data-floating].svelte-ddsc3z.svelte-ddsc3z{background:var(--altcha-color-base, white);display:none;filter:drop-shadow(3px 3px 6px rgba(0, 0, 0, 0.2));left:-100%;position:fixed;top:-100%;width:var(--altcha-max-width, 260px);z-index:999999}.altcha[data-floating=top].svelte-ddsc3z .altcha-anchor-arrow.svelte-ddsc3z{border-bottom-color:transparent;border-top-color:var(--altcha-color-border, #a0a0a0);bottom:-12px;top:auto}.altcha[data-floating=bottom].svelte-ddsc3z.svelte-ddsc3z:focus-within::after{border-bottom-color:var(--altcha-color-border-focus, currentColor)}.altcha[data-floating=top].svelte-ddsc3z.svelte-ddsc3z:focus-within::after{border-top-color:var(--altcha-color-border-focus, currentColor)}.altcha[data-floating].svelte-ddsc3z.svelte-ddsc3z:not([data-state=unverified]){display:block}.altcha-anchor-arrow.svelte-ddsc3z.svelte-ddsc3z{border:6px solid transparent;border-bottom-color:var(--altcha-color-border, #a0a0a0);content:"";height:0;left:12px;position:absolute;top:-12px;width:0}.altcha-main.svelte-ddsc3z.svelte-ddsc3z{align-items:center;display:flex;gap:0.4rem;padding:0.7rem}.altcha-label.svelte-ddsc3z.svelte-ddsc3z{flex-grow:1}.altcha-label.svelte-ddsc3z label.svelte-ddsc3z{cursor:pointer}.altcha-logo.svelte-ddsc3z.svelte-ddsc3z{color:currentColor;opacity:0.3}.altcha-logo.svelte-ddsc3z.svelte-ddsc3z:hover{opacity:1}.altcha-error.svelte-ddsc3z.svelte-ddsc3z{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-ddsc3z.svelte-ddsc3z{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-ddsc3z.svelte-ddsc3z:hover{opacity:1}.altcha-footer.svelte-ddsc3z>.svelte-ddsc3z:first-child{flex-grow:1}.altcha-footer.svelte-ddsc3z a{color:currentColor}.altcha-checkbox.svelte-ddsc3z.svelte-ddsc3z{display:flex;align-items:center;height:24px;width:24px}.altcha-checkbox.svelte-ddsc3z input.svelte-ddsc3z{width:18px;height:18px;margin:0}.altcha-hidden.svelte-ddsc3z.svelte-ddsc3z{display:none}.altcha-spinner.svelte-ddsc3z.svelte-ddsc3z{animation:svelte-ddsc3z-altcha-spinner 0.75s infinite linear;transform-origin:center}@keyframes svelte-ddsc3z-altcha-spinner{100%{transform:rotate(360deg)}}');
526
526
  }
527
- function He(r) {
527
+ function Oe(r) {
528
528
  let e, t, i;
529
529
  return {
530
530
  c() {
@@ -534,7 +534,7 @@ function He(r) {
534
534
  $(o, e, l), _(e, t), _(e, i);
535
535
  },
536
536
  d(o) {
537
- o && Z(e);
537
+ o && T(e);
538
538
  }
539
539
  };
540
540
  }
@@ -559,7 +559,7 @@ function qt(r) {
559
559
  o[4] + "_checkbox") && c(e, "for", i);
560
560
  },
561
561
  d(o) {
562
- o && Z(e);
562
+ o && T(e);
563
563
  }
564
564
  };
565
565
  }
@@ -581,7 +581,7 @@ function Qt(r) {
581
581
  i[11].verifying + "") && (e.innerHTML = t);
582
582
  },
583
583
  d(i) {
584
- i && Z(e);
584
+ i && T(e);
585
585
  }
586
586
  };
587
587
  }
@@ -617,36 +617,36 @@ function er(r) {
617
617
  l[5]);
618
618
  },
619
619
  d(l) {
620
- l && (Z(e), Z(i), Z(o));
620
+ l && (T(e), T(i), T(o));
621
621
  }
622
622
  };
623
623
  }
624
- function Oe(r) {
624
+ function Ye(r) {
625
625
  let e, t, i, o, l, s, u;
626
626
  return {
627
627
  c() {
628
- e = A("div"), t = A("a"), i = B("svg"), o = B("path"), l = B("path"), s = B("path"), c(o, "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(o, "fill", "currentColor"), c(l, "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(l, "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", lt), c(t, "target", "_blank"), c(t, "class", "altcha-logo svelte-ddsc3z"), c(t, "aria-label", u = /*_strings*/
628
+ e = A("div"), t = A("a"), i = B("svg"), o = B("path"), l = B("path"), s = B("path"), c(o, "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(o, "fill", "currentColor"), c(l, "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(l, "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", st), c(t, "target", "_blank"), c(t, "class", "altcha-logo svelte-ddsc3z"), c(t, "aria-label", u = /*_strings*/
629
629
  r[11].ariaLinkLabel);
630
630
  },
631
- m(a, d) {
632
- $(a, e, d), _(e, t), _(t, i), _(i, o), _(i, l), _(i, s);
631
+ m(f, d) {
632
+ $(f, e, d), _(e, t), _(t, i), _(i, o), _(i, l), _(i, s);
633
633
  },
634
- p(a, d) {
634
+ p(f, d) {
635
635
  d[0] & /*_strings*/
636
636
  2048 && u !== (u = /*_strings*/
637
- a[11].ariaLinkLabel) && c(t, "aria-label", u);
637
+ f[11].ariaLinkLabel) && c(t, "aria-label", u);
638
638
  },
639
- d(a) {
640
- a && Z(e);
639
+ d(f) {
640
+ f && T(e);
641
641
  }
642
642
  };
643
643
  }
644
- function Ye(r) {
644
+ function Pe(r) {
645
645
  let e, t, i, o;
646
- function l(a, d) {
646
+ function l(f, d) {
647
647
  return (
648
648
  /*state*/
649
- a[6] === b.EXPIRED ? rr : tr
649
+ f[6] === b.EXPIRED ? rr : tr
650
650
  );
651
651
  }
652
652
  let s = l(r), u = s(r);
@@ -654,14 +654,14 @@ function Ye(r) {
654
654
  c() {
655
655
  e = A("div"), t = B("svg"), i = B("path"), o = Y(), u.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-ddsc3z");
656
656
  },
657
- m(a, d) {
658
- $(a, e, d), _(e, t), _(t, i), _(e, o), u.m(e, null);
657
+ m(f, d) {
658
+ $(f, e, d), _(e, t), _(t, i), _(e, o), u.m(e, null);
659
659
  },
660
- p(a, d) {
661
- s === (s = l(a)) && u ? u.p(a, d) : (u.d(1), u = s(a), u && (u.c(), u.m(e, null)));
660
+ p(f, d) {
661
+ s === (s = l(f)) && u ? u.p(f, d) : (u.d(1), u = s(f), u && (u.c(), u.m(e, null)));
662
662
  },
663
- d(a) {
664
- a && Z(e), u.d();
663
+ d(f) {
664
+ f && T(e), u.d();
665
665
  }
666
666
  };
667
667
  }
@@ -694,7 +694,7 @@ function tr(r) {
694
694
  );
695
695
  },
696
696
  d(i) {
697
- i && Z(e);
697
+ i && T(e);
698
698
  }
699
699
  };
700
700
  }
@@ -727,11 +727,11 @@ function rr(r) {
727
727
  );
728
728
  },
729
729
  d(i) {
730
- i && Z(e);
730
+ i && T(e);
731
731
  }
732
732
  };
733
733
  }
734
- function Pe(r) {
734
+ function Ke(r) {
735
735
  let e, t, i = (
736
736
  /*_strings*/
737
737
  r[11].footer + ""
@@ -749,11 +749,11 @@ function Pe(r) {
749
749
  o[11].footer + "") && (t.innerHTML = i);
750
750
  },
751
751
  d(o) {
752
- o && Z(e);
752
+ o && T(e);
753
753
  }
754
754
  };
755
755
  }
756
- function Ke(r) {
756
+ function Je(r) {
757
757
  let e;
758
758
  return {
759
759
  c() {
@@ -764,14 +764,14 @@ function Ke(r) {
764
764
  },
765
765
  p: ne,
766
766
  d(t) {
767
- t && Z(e), r[36](null);
767
+ t && T(e), r[36](null);
768
768
  }
769
769
  };
770
770
  }
771
771
  function nr(r) {
772
- let e, t, i, o, l, s, u, a, d, U, S, D, k, F, P, N = (
772
+ let e, t, i, o, l, s, u, f, d, U, S, D, k, F, P, N = (
773
773
  /*state*/
774
- r[6] === b.VERIFYING && He()
774
+ r[6] === b.VERIFYING && Oe()
775
775
  );
776
776
  function Q(h, y) {
777
777
  return (
@@ -784,24 +784,24 @@ function nr(r) {
784
784
  }
785
785
  let H = Q(r), j = H(r), L = (
786
786
  /*hidelogo*/
787
- r[3] !== !0 && Oe(r)
787
+ r[3] !== !0 && Ye(r)
788
788
  ), R = (
789
789
  /*error*/
790
790
  (r[10] || /*state*/
791
- r[6] === b.EXPIRED) && Ye(r)
792
- ), v = (
791
+ r[6] === b.EXPIRED) && Pe(r)
792
+ ), w = (
793
793
  /*_strings*/
794
794
  r[11].footer && /*hidefooter*/
795
- r[2] !== !0 && Pe(r)
795
+ r[2] !== !0 && Ke(r)
796
796
  ), z = (
797
797
  /*floating*/
798
- r[1] && Ke(r)
798
+ r[1] && Je(r)
799
799
  );
800
800
  return {
801
801
  c() {
802
- e = A("div"), t = A("div"), N && N.c(), i = Y(), o = A("div"), l = A("input"), a = Y(), d = A("div"), j.c(), U = Y(), L && L.c(), S = Y(), R && R.c(), D = Y(), v && v.c(), k = Y(), z && z.c(), c(l, "type", "checkbox"), c(l, "id", s = /*name*/
802
+ e = A("div"), t = A("div"), N && N.c(), i = Y(), o = A("div"), l = A("input"), f = Y(), d = A("div"), j.c(), U = Y(), L && L.c(), S = Y(), R && R.c(), D = Y(), w && w.c(), k = Y(), z && z.c(), c(l, "type", "checkbox"), c(l, "id", s = /*name*/
803
803
  r[4] + "_checkbox"), l.required = u = /*auto*/
804
- r[0] !== "onsubmit", c(l, "class", "svelte-ddsc3z"), c(o, "class", "altcha-checkbox svelte-ddsc3z"), Xe(
804
+ r[0] !== "onsubmit", c(l, "class", "svelte-ddsc3z"), c(o, "class", "altcha-checkbox svelte-ddsc3z"), Be(
805
805
  o,
806
806
  "altcha-hidden",
807
807
  /*state*/
@@ -820,20 +820,20 @@ function nr(r) {
820
820
  },
821
821
  m(h, y) {
822
822
  $(h, e, y), _(e, t), N && N.m(t, null), _(t, i), _(t, o), _(o, l), l.checked = /*checked*/
823
- r[7], _(t, a), _(t, d), j.m(d, null), _(t, U), L && L.m(t, null), _(e, S), R && R.m(e, null), _(e, D), v && v.m(e, null), _(e, k), z && z.m(e, null), r[37](e), F || (P = [
824
- ve(
823
+ r[7], _(t, f), _(t, d), j.m(d, null), _(t, U), L && L.m(t, null), _(e, S), R && R.m(e, null), _(e, D), w && w.m(e, null), _(e, k), z && z.m(e, null), r[37](e), F || (P = [
824
+ ke(
825
825
  l,
826
826
  "change",
827
827
  /*input_change_handler*/
828
828
  r[35]
829
829
  ),
830
- ve(
830
+ ke(
831
831
  l,
832
832
  "change",
833
833
  /*onCheckedChange*/
834
834
  r[12]
835
835
  ),
836
- ve(
836
+ ke(
837
837
  l,
838
838
  "invalid",
839
839
  /*onInvalid*/
@@ -843,25 +843,25 @@ function nr(r) {
843
843
  },
844
844
  p(h, y) {
845
845
  /*state*/
846
- h[6] === b.VERIFYING ? N || (N = He(), N.c(), N.m(t, i)) : N && (N.d(1), N = null), y[0] & /*name*/
846
+ h[6] === b.VERIFYING ? N || (N = Oe(), N.c(), N.m(t, i)) : N && (N.d(1), N = null), y[0] & /*name*/
847
847
  16 && s !== (s = /*name*/
848
848
  h[4] + "_checkbox") && c(l, "id", s), y[0] & /*auto*/
849
849
  1 && u !== (u = /*auto*/
850
850
  h[0] !== "onsubmit") && (l.required = u), y[0] & /*checked*/
851
851
  128 && (l.checked = /*checked*/
852
852
  h[7]), y[0] & /*state*/
853
- 64 && Xe(
853
+ 64 && Be(
854
854
  o,
855
855
  "altcha-hidden",
856
856
  /*state*/
857
857
  h[6] === b.VERIFYING
858
858
  ), H === (H = Q(h)) && j ? j.p(h, y) : (j.d(1), j = H(h), j && (j.c(), j.m(d, null))), /*hidelogo*/
859
- h[3] !== !0 ? L ? L.p(h, y) : (L = Oe(h), L.c(), L.m(t, null)) : L && (L.d(1), L = null), /*error*/
859
+ h[3] !== !0 ? L ? L.p(h, y) : (L = Ye(h), L.c(), L.m(t, null)) : L && (L.d(1), L = null), /*error*/
860
860
  h[10] || /*state*/
861
- h[6] === b.EXPIRED ? R ? R.p(h, y) : (R = Ye(h), R.c(), R.m(e, D)) : R && (R.d(1), R = null), /*_strings*/
861
+ h[6] === b.EXPIRED ? R ? R.p(h, y) : (R = Pe(h), R.c(), R.m(e, D)) : R && (R.d(1), R = null), /*_strings*/
862
862
  h[11].footer && /*hidefooter*/
863
- h[2] !== !0 ? v ? v.p(h, y) : (v = Pe(h), v.c(), v.m(e, k)) : v && (v.d(1), v = null), /*floating*/
864
- h[1] ? z ? z.p(h, y) : (z = Ke(h), z.c(), z.m(e, null)) : z && (z.d(1), z = null), y[0] & /*state*/
863
+ h[2] !== !0 ? w ? w.p(h, y) : (w = Ke(h), w.c(), w.m(e, k)) : w && (w.d(1), w = null), /*floating*/
864
+ h[1] ? z ? z.p(h, y) : (z = Je(h), z.c(), z.m(e, null)) : z && (z.d(1), z = null), y[0] & /*state*/
865
865
  64 && c(
866
866
  e,
867
867
  "data-state",
@@ -878,12 +878,12 @@ function nr(r) {
878
878
  i: ne,
879
879
  o: ne,
880
880
  d(h) {
881
- h && Z(e), N && N.d(), j.d(), L && L.d(), R && R.d(), v && v.d(), z && z.d(), r[37](null), F = !1, se(P);
881
+ h && T(e), N && N.d(), j.d(), L && L.d(), R && R.d(), w && w.d(), z && z.d(), r[37](null), F = !1, ae(P);
882
882
  }
883
883
  };
884
884
  }
885
- const Je = "Visit Altcha.org", lt = "https://altcha.org/";
886
- function qe(r) {
885
+ const qe = "Visit Altcha.org", st = "https://altcha.org/";
886
+ function Qe(r) {
887
887
  return JSON.parse(r);
888
888
  }
889
889
  function ir() {
@@ -893,279 +893,283 @@ function ir() {
893
893
  }
894
894
  }
895
895
  function or(r, e, t) {
896
- var Ve, $e;
897
- let i, o, l, { auto: s = void 0 } = e, { blockspam: u = void 0 } = e, { challengeurl: a = void 0 } = e, { challengejson: d = void 0 } = e, { debug: U = !1 } = e, { delay: S = 0 } = e, { expire: D = void 0 } = e, { floating: k = void 0 } = e, { floatinganchor: F = void 0 } = e, { floatingoffset: P = void 0 } = e, { hidefooter: N = !1 } = e, { hidelogo: Q = !1 } = e, { name: H = "altcha" } = e, { maxnumber: j = 1e6 } = e, { mockerror: L = !1 } = e, { refetchonexpire: R = !0 } = e, { spamfilter: v = !1 } = e, { strings: z = void 0 } = e, { test: h = !1 } = e, { verifyurl: y = void 0 } = e, { workers: ie = Math.min(16, navigator.hardwareConcurrency || 8) } = e, { workerurl: ge = void 0 } = e;
898
- const me = Tt(), xe = ["SHA-256", "SHA-384", "SHA-512"], Ee = ($e = (Ve = document.documentElement.lang) == null ? void 0 : Ve.split("-")) == null ? void 0 : $e[0];
899
- let O = !1, E, K = null, ce = null, m = null, be = null, J = null, M = b.UNVERIFIED, W = null;
896
+ var Fe, Ge;
897
+ let i, o, l, { auto: s = void 0 } = e, { blockspam: u = void 0 } = e, { challengeurl: f = void 0 } = e, { challengejson: d = void 0 } = e, { debug: U = !1 } = e, { delay: S = 0 } = e, { expire: D = void 0 } = e, { floating: k = void 0 } = e, { floatinganchor: F = void 0 } = e, { floatingoffset: P = void 0 } = e, { hidefooter: N = !1 } = e, { hidelogo: Q = !1 } = e, { name: H = "altcha" } = e, { maxnumber: j = 1e6 } = e, { mockerror: L = !1 } = e, { refetchonexpire: R = !0 } = e, { spamfilter: w = !1 } = e, { strings: z = void 0 } = e, { test: h = !1 } = e, { verifyurl: y = void 0 } = e, { workers: ie = Math.min(16, navigator.hardwareConcurrency || 8) } = e, { workerurl: ve = void 0 } = e;
898
+ const we = Tt(), Re = ["SHA-256", "SHA-384", "SHA-512"], ze = (Ge = (Fe = document.documentElement.lang) == null ? void 0 : Fe.split("-")) == null ? void 0 : Ge[0];
899
+ let O = !1, x, K = null, fe = null, m = null, ye = null, J = null, Z = b.UNVERIFIED, W = null;
900
900
  jt(() => {
901
- m && (m.removeEventListener("submit", Le), m.removeEventListener("reset", Re), m.removeEventListener("focusin", Ce), m = null), W && (clearTimeout(W), W = null), document.removeEventListener("click", Ne), document.removeEventListener("scroll", Se), window.removeEventListener("resize", Te);
901
+ m && (m.removeEventListener("submit", Ae), m.removeEventListener("reset", Ne), m.removeEventListener("focusin", Ie), m = null), W && (clearTimeout(W), W = null), document.removeEventListener("click", Ze), document.removeEventListener("scroll", Me), window.removeEventListener("resize", $e);
902
902
  }), St(() => {
903
- C("mounted", "0.6.1"), C("workers", ie), h && C("using test mode"), D && ae(D), s !== void 0 && C("auto", s), k !== void 0 && Ze(k), m = E.closest("form"), m && (m.addEventListener("submit", Le, { capture: !0 }), m.addEventListener("reset", Re), s === "onfocus" && m.addEventListener("focusin", Ce)), s === "onload" && q();
903
+ E("mounted", "0.6.2"), E("workers", ie), h && E("using test mode"), D && ue(D), s !== void 0 && E("auto", s), k !== void 0 && De(k), m = x.closest("form"), m && (m.addEventListener("submit", Ae, { capture: !0 }), m.addEventListener("reset", Ne), s === "onfocus" && m.addEventListener("focusin", Ie)), s === "onload" && q();
904
904
  });
905
- function C(...n) {
906
- (U || n.some((f) => f instanceof Error)) && console[n[0] instanceof Error ? "error" : "log"]("ALTCHA", ...n);
905
+ function E(...n) {
906
+ (U || n.some((a) => a instanceof Error)) && console[n[0] instanceof Error ? "error" : "log"]("ALTCHA", ...n);
907
907
  }
908
- function Ce(n) {
909
- M === b.UNVERIFIED && q();
908
+ function Ie(n) {
909
+ Z === b.UNVERIFIED && q();
910
910
  }
911
- function Le(n) {
912
- m && s === "onsubmit" && (M === b.UNVERIFIED ? (n.preventDefault(), n.stopPropagation(), q().then(() => {
911
+ function Ae(n) {
912
+ m && s === "onsubmit" && (Z === b.UNVERIFIED ? (n.preventDefault(), n.stopPropagation(), q().then(() => {
913
913
  m == null || m.requestSubmit();
914
- })) : M !== b.VERIFIED && (n.preventDefault(), n.stopPropagation(), M === b.VERIFYING && je()));
914
+ })) : Z !== b.VERIFIED && (n.preventDefault(), n.stopPropagation(), Z === b.VERIFYING && Ve()));
915
915
  }
916
- function Re() {
917
- fe();
916
+ function Ne() {
917
+ de();
918
918
  }
919
- function ze(n, f) {
919
+ function Se(n, a) {
920
920
  return btoa(JSON.stringify({
921
921
  algorithm: n.algorithm,
922
922
  challenge: n.challenge,
923
- number: f.number,
923
+ number: a.number,
924
924
  salt: n.salt,
925
925
  signature: n.signature,
926
926
  test: h ? !0 : void 0,
927
- took: f.took
927
+ took: a.took
928
928
  }));
929
929
  }
930
- function Ie(n) {
930
+ function je(n) {
931
931
  if (!n.algorithm)
932
932
  throw new Error("Invalid challenge. Property algorithm is missing.");
933
933
  if (n.signature === void 0)
934
934
  throw new Error("Invalid challenge. Property signature is missing.");
935
- if (!xe.includes(n.algorithm.toUpperCase()))
936
- throw new Error(`Unknown algorithm value. Allowed values: ${xe.join(", ")}`);
935
+ if (!Re.includes(n.algorithm.toUpperCase()))
936
+ throw new Error(`Unknown algorithm value. Allowed values: ${Re.join(", ")}`);
937
937
  if (!n.challenge || n.challenge.length < 40)
938
938
  throw new Error("Challenge is too short. Min. 40 chars.");
939
939
  if (!n.salt || n.salt.length < 10)
940
940
  throw new Error("Salt is too short. Min. 10 chars.");
941
941
  }
942
- async function st() {
942
+ async function ct() {
943
943
  var n;
944
944
  if (L)
945
- throw C("mocking error"), new Error("Mocked error.");
945
+ throw E("mocking error"), new Error("Mocked error.");
946
946
  if (i)
947
- return C("using provided json data"), i;
947
+ return E("using provided json data"), i;
948
948
  if (h)
949
- return C("generating test challenge", { test: h }), Pt(typeof h != "boolean" ? +h : void 0);
949
+ return E("generating test challenge", { test: h }), Pt(typeof h != "boolean" ? +h : void 0);
950
950
  {
951
- if (!a)
951
+ if (!f)
952
952
  throw new Error("Attribute challengeurl not set.");
953
- C("fetching challenge from", a);
954
- const f = await fetch(a, {
953
+ E("fetching challenge from", f);
954
+ const a = await fetch(f, {
955
955
  headers: {
956
- "x-altcha-spam-filter": v ? "1" : "0"
956
+ "x-altcha-spam-filter": w ? "1" : "0"
957
957
  }
958
958
  });
959
- if (f.status !== 200)
960
- throw new Error(`Server responded with ${f.status}.`);
961
- const g = f.headers.get("Expires"), I = f.headers.get("X-Altcha-Config"), T = await f.json(), V = new URLSearchParams((n = T.salt.split("?")) == null ? void 0 : n[1]), X = V.get("expires") || V.get("expire");
959
+ if (a.status !== 200)
960
+ throw new Error(`Server responded with ${a.status}.`);
961
+ const g = a.headers.get("Expires"), I = a.headers.get("X-Altcha-Config"), M = await a.json(), V = new URLSearchParams((n = M.salt.split("?")) == null ? void 0 : n[1]), X = V.get("expires") || V.get("expire");
962
962
  if (X) {
963
- const p = new Date(+X * 1e3), x = isNaN(p.getTime()) ? 0 : p.getTime() - Date.now();
964
- x > 0 && ae(x);
963
+ const p = new Date(+X * 1e3), C = isNaN(p.getTime()) ? 0 : p.getTime() - Date.now();
964
+ C > 0 && ue(C);
965
965
  }
966
966
  if (I)
967
967
  try {
968
968
  const p = JSON.parse(I);
969
- p && typeof p == "object" && (p.verifyurl && (p.verifyurl = new URL(p.verifyurl, new URL(a)).toString()), Me(p));
969
+ p && typeof p == "object" && (p.verifyurl && (p.verifyurl = new URL(p.verifyurl, new URL(f)).toString()), Ue(p));
970
970
  } catch (p) {
971
- C("unable to configure from X-Altcha-Config", p);
971
+ E("unable to configure from X-Altcha-Config", p);
972
972
  }
973
973
  if (!D && (g != null && g.length)) {
974
974
  const p = Date.parse(g);
975
975
  if (p) {
976
- const x = p - Date.now();
977
- x > 0 && ae(x);
976
+ const C = p - Date.now();
977
+ C > 0 && ue(C);
978
978
  }
979
979
  }
980
- return T;
980
+ return M;
981
981
  }
982
982
  }
983
- function Ae() {
984
- a && R && M === b.VERIFIED ? q() : fe(b.EXPIRED, l.expired);
983
+ function Te() {
984
+ f && R && Z === b.VERIFIED ? q() : de(b.EXPIRED, l.expired);
985
985
  }
986
- async function ct(n) {
987
- let f = null;
986
+ async function at(n) {
987
+ let a = null;
988
988
  if ("Worker" in window) {
989
989
  try {
990
- f = await at(n.challenge, n.salt, n.algorithm, n.maxnumber);
990
+ a = await ft(n.challenge, n.salt, n.algorithm, n.maxnumber);
991
991
  } catch (g) {
992
- C(g);
992
+ E(g);
993
993
  }
994
- if ((f == null ? void 0 : f.number) !== void 0)
995
- return { data: n, solution: f };
994
+ if ((a == null ? void 0 : a.number) !== void 0)
995
+ return { data: n, solution: a };
996
996
  }
997
997
  return {
998
998
  data: n,
999
999
  solution: await Kt(n.challenge, n.salt, n.algorithm, n.maxnumber || j).promise
1000
1000
  };
1001
1001
  }
1002
- async function at(n, f, g, I = typeof h == "number" ? h : j, T = Math.ceil(ie)) {
1002
+ async function ft(n, a, g, I = typeof h == "number" ? h : j, M = Math.ceil(ie)) {
1003
1003
  const V = [];
1004
- if (T < 1)
1004
+ if (M < 1)
1005
1005
  throw new Error("Wrong number of workers configured.");
1006
- if (T > 16)
1006
+ if (M > 16)
1007
1007
  throw new Error("Too many workers. Max. 16 allowed workers.");
1008
- for (let x = 0; x < T; x++)
1009
- V.push(createAltchaWorker(ge));
1010
- const X = Math.ceil(I / T), p = await Promise.all(V.map((x, ue) => {
1011
- const De = ue * X;
1012
- return new Promise((vt) => {
1013
- x.addEventListener("message", (Ue) => {
1014
- if (Ue.data)
1015
- for (const Fe of V)
1016
- Fe !== x && Fe.postMessage({ type: "abort" });
1017
- vt(Ue.data);
1018
- }), x.postMessage({
1008
+ for (let C = 0; C < M; C++)
1009
+ V.push(createAltchaWorker(ve));
1010
+ const X = Math.ceil(I / M), p = await Promise.all(V.map((C, _e) => {
1011
+ const oe = _e * X;
1012
+ return new Promise((he) => {
1013
+ C.addEventListener("message", (ge) => {
1014
+ if (ge.data)
1015
+ for (const le of V)
1016
+ le !== C && le.postMessage({ type: "abort" });
1017
+ he(ge.data);
1018
+ }), C.postMessage({
1019
1019
  payload: {
1020
1020
  alg: g,
1021
1021
  challenge: n,
1022
- max: De + X,
1023
- salt: f,
1024
- start: De
1022
+ max: oe + X,
1023
+ salt: a,
1024
+ start: oe
1025
1025
  },
1026
1026
  type: "work"
1027
1027
  });
1028
1028
  });
1029
1029
  }));
1030
- for (const x of V)
1031
- x.terminate();
1032
- return p.find((x) => !!x) || null;
1030
+ for (const C of V)
1031
+ C.terminate();
1032
+ return p.find((C) => !!C) || null;
1033
1033
  }
1034
- function ft() {
1035
- [b.UNVERIFIED, b.ERROR, b.EXPIRED].includes(M) ? v && (m == null ? void 0 : m.reportValidity()) === !1 ? t(7, O = !1) : q() : t(7, O = !0);
1034
+ function ut() {
1035
+ [b.UNVERIFIED, b.ERROR, b.EXPIRED].includes(Z) ? w && (m == null ? void 0 : m.reportValidity()) === !1 ? t(7, O = !1) : q() : t(7, O = !0);
1036
1036
  }
1037
- function Ne(n) {
1038
- const f = n.target;
1039
- k && f && !E.contains(f) && M === b.VERIFIED && t(8, E.style.display = "none", E);
1037
+ function Ze(n) {
1038
+ const a = n.target;
1039
+ k && a && !x.contains(a) && Z === b.VERIFIED && t(8, x.style.display = "none", x);
1040
1040
  }
1041
- function Se() {
1042
- k && we();
1041
+ function Me() {
1042
+ k && pe();
1043
1043
  }
1044
- function je() {
1045
- M === b.VERIFYING && l.waitAlert && alert(l.waitAlert);
1044
+ function Ve() {
1045
+ Z === b.VERIFYING && l.waitAlert && alert(l.waitAlert);
1046
1046
  }
1047
- function ut(n) {
1048
- k && M !== b.UNVERIFIED && requestAnimationFrame(() => {
1049
- we();
1047
+ function dt(n) {
1048
+ k && Z !== b.UNVERIFIED && requestAnimationFrame(() => {
1049
+ pe();
1050
1050
  });
1051
1051
  }
1052
- function Te() {
1053
- k && we();
1052
+ function $e() {
1053
+ k && pe();
1054
1054
  }
1055
- function ae(n) {
1056
- C("expire", n), W && (clearTimeout(W), W = null), n < 1 ? Ae() : W = setTimeout(Ae, n);
1055
+ function ue(n) {
1056
+ E("expire", n), W && (clearTimeout(W), W = null), n < 1 ? Te() : W = setTimeout(Te, n);
1057
1057
  }
1058
- function Ze(n) {
1059
- C("floating", n), k !== n && (t(8, E.style.left = "", E), t(8, E.style.top = "", E)), t(1, k = n === !0 || n === "" ? "auto" : n === !1 || n === "false" ? void 0 : k), k ? (s || t(0, s = "onsubmit"), document.addEventListener("scroll", Se), document.addEventListener("click", Ne), window.addEventListener("resize", Te)) : s === "onsubmit" && t(0, s = void 0);
1058
+ function De(n) {
1059
+ E("floating", n), k !== n && (t(8, x.style.left = "", x), t(8, x.style.top = "", x)), t(1, k = n === !0 || n === "" ? "auto" : n === !1 || n === "false" ? void 0 : k), k ? (s || t(0, s = "onsubmit"), document.addEventListener("scroll", Me), document.addEventListener("click", Ze), window.addEventListener("resize", $e)) : s === "onsubmit" && t(0, s = void 0);
1060
1060
  }
1061
- function dt(n) {
1061
+ function ht(n) {
1062
1062
  var g;
1063
- const f = m == null ? void 0 : m.querySelector(typeof n == "string" ? `input[name="${n}"]` : 'input[type="email"]:not([data-no-spamfilter])');
1064
- return ((g = f == null ? void 0 : f.value) == null ? void 0 : g.slice(f.value.indexOf("@"))) || void 0;
1063
+ const a = m == null ? void 0 : m.querySelector(typeof n == "string" ? `input[name="${n}"]` : 'input[type="email"]:not([data-no-spamfilter])');
1064
+ return ((g = a == null ? void 0 : a.value) == null ? void 0 : g.slice(a.value.indexOf("@"))) || void 0;
1065
1065
  }
1066
- function ht(n) {
1066
+ function gt(n) {
1067
1067
  return [
1068
1068
  ...(m == null ? void 0 : m.querySelectorAll(n != null && n.length ? n.map((g) => `input[name="${g}"]`).join(", ") : 'input[type="text"]:not([data-no-spamfilter]), textarea:not([data-no-spamfilter])')) || []
1069
1069
  ].reduce(
1070
1070
  (g, I) => {
1071
- const T = I.name, V = I.value.trim();
1072
- return T && V && (g[T] = V), g;
1071
+ const M = I.name, V = I.value.trim();
1072
+ return M && V && (g[M] = V), g;
1073
1073
  },
1074
1074
  {}
1075
1075
  );
1076
1076
  }
1077
- async function gt(n) {
1077
+ async function mt(n) {
1078
1078
  if (!y)
1079
1079
  throw new Error("Attribute verifyurl not set.");
1080
- C("requesting server verification from", y);
1081
- const f = { payload: n };
1082
- if (v) {
1083
- const { email: T, expectedLanguages: V, expectedCountries: X, fields: p, ipAddress: x, timeZone: ue } = typeof v == "object" ? v : {
1080
+ E("requesting server verification from", y);
1081
+ const a = { payload: n };
1082
+ if (w) {
1083
+ const { blockedCountries: M, classifier: V, disableRules: X, email: p, expectedLanguages: C, expectedCountries: _e, fields: oe, ipAddress: he, text: ge, timeZone: le } = typeof w == "object" ? w : {
1084
+ blockedCountries: void 0,
1085
+ classifier: void 0,
1086
+ disableRules: void 0,
1084
1087
  email: void 0,
1085
1088
  expectedCountries: void 0,
1086
1089
  expectedLanguages: void 0,
1087
1090
  fields: void 0,
1088
1091
  ipAddress: void 0,
1092
+ text: void 0,
1089
1093
  timeZone: void 0
1090
1094
  };
1091
- f.ipAddress = x === !1 ? void 0 : x || "auto", f.email = T === !1 ? void 0 : dt(T), f.fields = p === !1 ? void 0 : ht(p), f.timeZone = ue === !1 ? void 0 : ue || ir(), f.expectedCountries = X, f.expectedLanguages = V || (Ee ? [Ee] : void 0);
1095
+ a.blockedCountries = M, a.classifier = V, a.disableRules = X, a.email = p === !1 ? void 0 : ht(p), a.expectedCountries = _e, a.expectedLanguages = C || (ze ? [ze] : void 0), a.fields = oe === !1 ? void 0 : gt(oe), a.ipAddress = he === !1 ? void 0 : he || "auto", a.text = ge, a.timeZone = le === !1 ? void 0 : le || ir();
1092
1096
  }
1093
1097
  const g = await fetch(y, {
1094
- body: JSON.stringify(f),
1098
+ body: JSON.stringify(a),
1095
1099
  headers: { "content-type": "application/json" },
1096
1100
  method: "POST"
1097
1101
  });
1098
1102
  if (g.status !== 200)
1099
1103
  throw new Error(`Server responded with ${g.status}.`);
1100
1104
  const I = await g.json();
1101
- if (I != null && I.payload && t(5, J = I.payload), me("serververification", I), u && I.classification === "BAD")
1105
+ if (I != null && I.payload && t(5, J = I.payload), we("serververification", I), u && I.classification === "BAD")
1102
1106
  throw new Error("SpamFilter returned negative classification.");
1103
1107
  }
1104
- function we(n = 20) {
1105
- if (E)
1106
- if (ce || (ce = (F ? document.querySelector(F) : m == null ? void 0 : m.querySelector('input[type="submit"], button[type="submit"], button:not([type="button"]):not([type="reset"])')) || m), ce) {
1107
- const f = parseInt(P, 10) || 12, g = ce.getBoundingClientRect(), I = E.getBoundingClientRect(), T = document.documentElement.clientHeight, V = document.documentElement.clientWidth, X = k === "auto" ? g.bottom + I.height + f + n > T : k === "top", p = Math.max(n, Math.min(V - n - I.width, g.left + g.width / 2 - I.width / 2));
1108
- if (X ? t(8, E.style.top = `${g.top - (I.height + f)}px`, E) : t(8, E.style.top = `${g.bottom + f}px`, E), t(8, E.style.left = `${p}px`, E), E.setAttribute("data-floating", X ? "top" : "bottom"), K) {
1109
- const x = K.getBoundingClientRect();
1110
- t(9, K.style.left = g.left - p + g.width / 2 - x.width / 2 + "px", K);
1108
+ function pe(n = 20) {
1109
+ if (x)
1110
+ if (fe || (fe = (F ? document.querySelector(F) : m == null ? void 0 : m.querySelector('input[type="submit"], button[type="submit"], button:not([type="button"]):not([type="reset"])')) || m), fe) {
1111
+ const a = parseInt(P, 10) || 12, g = fe.getBoundingClientRect(), I = x.getBoundingClientRect(), M = document.documentElement.clientHeight, V = document.documentElement.clientWidth, X = k === "auto" ? g.bottom + I.height + a + n > M : k === "top", p = Math.max(n, Math.min(V - n - I.width, g.left + g.width / 2 - I.width / 2));
1112
+ if (X ? t(8, x.style.top = `${g.top - (I.height + a)}px`, x) : t(8, x.style.top = `${g.bottom + a}px`, x), t(8, x.style.left = `${p}px`, x), x.setAttribute("data-floating", X ? "top" : "bottom"), K) {
1113
+ const C = K.getBoundingClientRect();
1114
+ t(9, K.style.left = g.left - p + g.width / 2 - C.width / 2 + "px", K);
1111
1115
  }
1112
1116
  } else
1113
- C("unable to find floating anchor element");
1117
+ E("unable to find floating anchor element");
1114
1118
  }
1115
- function Me(n) {
1116
- n.auto !== void 0 && (t(0, s = n.auto), s === "onload" && q()), n.floatinganchor !== void 0 && t(18, F = n.floatinganchor), n.delay !== void 0 && t(16, S = n.delay), n.floatingoffset !== void 0 && t(19, P = n.floatingoffset), n.floating !== void 0 && Ze(n.floating), n.expire !== void 0 && (ae(n.expire), t(17, D = n.expire)), n.challenge && (Ie(n.challenge), i = n.challenge), n.challengeurl !== void 0 && t(14, a = n.challengeurl), n.debug !== void 0 && t(15, U = !!n.debug), n.hidefooter !== void 0 && t(2, N = !!n.hidefooter), n.hidelogo !== void 0 && t(3, Q = !!n.hidelogo), n.maxnumber !== void 0 && t(20, j = +n.maxnumber), n.mockerror !== void 0 && t(21, L = !!n.mockerror), n.name !== void 0 && t(4, H = n.name), n.refetchonexpire !== void 0 && t(22, R = !!n.refetchonexpire), n.spamfilter !== void 0 && t(23, v = typeof n.spamfilter == "object" ? n.spamfilter : !!n.spamfilter), n.strings && t(34, o = n.strings), n.test !== void 0 && t(24, h = typeof n.test == "number" ? n.test : !!n.test), n.verifyurl !== void 0 && t(25, y = n.verifyurl), n.workers !== void 0 && t(26, ie = +n.workers);
1119
+ function Ue(n) {
1120
+ n.auto !== void 0 && (t(0, s = n.auto), s === "onload" && q()), n.floatinganchor !== void 0 && t(18, F = n.floatinganchor), n.delay !== void 0 && t(16, S = n.delay), n.floatingoffset !== void 0 && t(19, P = n.floatingoffset), n.floating !== void 0 && De(n.floating), n.expire !== void 0 && (ue(n.expire), t(17, D = n.expire)), n.challenge && (je(n.challenge), i = n.challenge), n.challengeurl !== void 0 && t(14, f = n.challengeurl), n.debug !== void 0 && t(15, U = !!n.debug), n.hidefooter !== void 0 && t(2, N = !!n.hidefooter), n.hidelogo !== void 0 && t(3, Q = !!n.hidelogo), n.maxnumber !== void 0 && t(20, j = +n.maxnumber), n.mockerror !== void 0 && t(21, L = !!n.mockerror), n.name !== void 0 && t(4, H = n.name), n.refetchonexpire !== void 0 && t(22, R = !!n.refetchonexpire), n.spamfilter !== void 0 && t(23, w = typeof n.spamfilter == "object" ? n.spamfilter : !!n.spamfilter), n.strings && t(34, o = n.strings), n.test !== void 0 && t(24, h = typeof n.test == "number" ? n.test : !!n.test), n.verifyurl !== void 0 && t(25, y = n.verifyurl), n.workers !== void 0 && t(26, ie = +n.workers);
1117
1121
  }
1118
- function fe(n = b.UNVERIFIED, f = null) {
1119
- W && (clearTimeout(W), W = null), t(7, O = !1), t(10, be = f), t(5, J = null), t(6, M = n);
1122
+ function de(n = b.UNVERIFIED, a = null) {
1123
+ W && (clearTimeout(W), W = null), t(7, O = !1), t(10, ye = a), t(5, J = null), t(6, Z = n);
1120
1124
  }
1121
1125
  async function q() {
1122
- return fe(b.VERIFYING), await new Promise((n) => setTimeout(n, S || 0)), st().then((n) => (Ie(n), C("challenge", n), ct(n))).then(({ data: n, solution: f }) => {
1123
- if (C("solution", f), (f == null ? void 0 : f.number) !== void 0) {
1126
+ return de(b.VERIFYING), await new Promise((n) => setTimeout(n, S || 0)), ct().then((n) => (je(n), E("challenge", n), at(n))).then(({ data: n, solution: a }) => {
1127
+ if (E("solution", a), (a == null ? void 0 : a.number) !== void 0) {
1124
1128
  if (y)
1125
- return gt(ze(n, f));
1126
- t(5, J = ze(n, f)), C("payload", J);
1129
+ return mt(Se(n, a));
1130
+ t(5, J = Se(n, a)), E("payload", J);
1127
1131
  } else
1128
- throw C("Unable to find a solution. Ensure that the 'maxnumber' attribute is greater than the randomly generated number."), new Error("Unexpected result returned.");
1132
+ throw E("Unable to find a solution. Ensure that the 'maxnumber' attribute is greater than the randomly generated number."), new Error("Unexpected result returned.");
1129
1133
  }).then(() => {
1130
1134
  Zt().then(() => {
1131
- t(6, M = b.VERIFIED), t(7, O = !0), C("verified"), me("verified", { payload: J });
1135
+ t(6, Z = b.VERIFIED), t(7, O = !0), E("verified"), we("verified", { payload: J });
1132
1136
  });
1133
1137
  }).catch((n) => {
1134
- C(n), t(6, M = b.ERROR), t(7, O = !1), t(10, be = n.message);
1138
+ E(n), t(6, Z = b.ERROR), t(7, O = !1), t(10, ye = n.message);
1135
1139
  });
1136
1140
  }
1137
- function mt() {
1141
+ function bt() {
1138
1142
  O = this.checked, t(7, O);
1139
1143
  }
1140
- function bt(n) {
1141
- he[n ? "unshift" : "push"](() => {
1144
+ function vt(n) {
1145
+ be[n ? "unshift" : "push"](() => {
1142
1146
  K = n, t(9, K);
1143
1147
  });
1144
1148
  }
1145
1149
  function wt(n) {
1146
- he[n ? "unshift" : "push"](() => {
1147
- E = n, t(8, E);
1150
+ be[n ? "unshift" : "push"](() => {
1151
+ x = n, t(8, x);
1148
1152
  });
1149
1153
  }
1150
1154
  return r.$$set = (n) => {
1151
- "auto" in n && t(0, s = n.auto), "blockspam" in n && t(27, u = n.blockspam), "challengeurl" in n && t(14, a = n.challengeurl), "challengejson" in n && t(28, d = n.challengejson), "debug" in n && t(15, U = n.debug), "delay" in n && t(16, S = n.delay), "expire" in n && t(17, D = n.expire), "floating" in n && t(1, k = n.floating), "floatinganchor" in n && t(18, F = n.floatinganchor), "floatingoffset" in n && t(19, P = n.floatingoffset), "hidefooter" in n && t(2, N = n.hidefooter), "hidelogo" in n && t(3, Q = n.hidelogo), "name" in n && t(4, H = n.name), "maxnumber" in n && t(20, j = n.maxnumber), "mockerror" in n && t(21, L = n.mockerror), "refetchonexpire" in n && t(22, R = n.refetchonexpire), "spamfilter" in n && t(23, v = n.spamfilter), "strings" in n && t(29, z = n.strings), "test" in n && t(24, h = n.test), "verifyurl" in n && t(25, y = n.verifyurl), "workers" in n && t(26, ie = n.workers), "workerurl" in n && t(30, ge = n.workerurl);
1155
+ "auto" in n && t(0, s = n.auto), "blockspam" in n && t(27, u = n.blockspam), "challengeurl" in n && t(14, f = n.challengeurl), "challengejson" in n && t(28, d = n.challengejson), "debug" in n && t(15, U = n.debug), "delay" in n && t(16, S = n.delay), "expire" in n && t(17, D = n.expire), "floating" in n && t(1, k = n.floating), "floatinganchor" in n && t(18, F = n.floatinganchor), "floatingoffset" in n && t(19, P = n.floatingoffset), "hidefooter" in n && t(2, N = n.hidefooter), "hidelogo" in n && t(3, Q = n.hidelogo), "name" in n && t(4, H = n.name), "maxnumber" in n && t(20, j = n.maxnumber), "mockerror" in n && t(21, L = n.mockerror), "refetchonexpire" in n && t(22, R = n.refetchonexpire), "spamfilter" in n && t(23, w = n.spamfilter), "strings" in n && t(29, z = n.strings), "test" in n && t(24, h = n.test), "verifyurl" in n && t(25, y = n.verifyurl), "workers" in n && t(26, ie = n.workers), "workerurl" in n && t(30, ve = n.workerurl);
1152
1156
  }, r.$$.update = () => {
1153
1157
  r.$$.dirty[0] & /*challengejson*/
1154
- 268435456 && (i = d ? qe(d) : void 0), r.$$.dirty[0] & /*strings*/
1155
- 536870912 && t(34, o = z ? qe(z) : {}), r.$$.dirty[1] & /*parsedStrings*/
1158
+ 268435456 && (i = d ? Qe(d) : void 0), r.$$.dirty[0] & /*strings*/
1159
+ 536870912 && t(34, o = z ? Qe(z) : {}), r.$$.dirty[1] & /*parsedStrings*/
1156
1160
  8 && t(11, l = {
1157
- ariaLinkLabel: Je,
1161
+ ariaLinkLabel: qe,
1158
1162
  error: "Verification failed. Try again later.",
1159
1163
  expired: "Verification expired. Try again.",
1160
- footer: `Protected by <a href="${lt}" target="_blank" aria-label="${o.ariaLinkLabel || Je}">ALTCHA</a>`,
1164
+ footer: `Protected by <a href="${st}" target="_blank" aria-label="${o.ariaLinkLabel || qe}">ALTCHA</a>`,
1161
1165
  label: "I'm not a robot",
1162
1166
  verified: "Verified",
1163
1167
  verifying: "Verifying...",
1164
1168
  waitAlert: "Verifying... please wait.",
1165
1169
  ...o
1166
1170
  }), r.$$.dirty[0] & /*payload, state*/
1167
- 96 && me("statechange", { payload: J, state: M }), r.$$.dirty[0] & /*state*/
1168
- 64 && ut();
1171
+ 96 && we("statechange", { payload: J, state: Z }), r.$$.dirty[0] & /*state*/
1172
+ 64 && dt();
1169
1173
  }, [
1170
1174
  s,
1171
1175
  k,
@@ -1173,15 +1177,15 @@ function or(r, e, t) {
1173
1177
  Q,
1174
1178
  H,
1175
1179
  J,
1176
- M,
1180
+ Z,
1177
1181
  O,
1178
- E,
1182
+ x,
1179
1183
  K,
1180
- be,
1184
+ ye,
1181
1185
  l,
1182
- ft,
1183
- je,
1184
- a,
1186
+ ut,
1187
+ Ve,
1188
+ f,
1185
1189
  U,
1186
1190
  S,
1187
1191
  D,
@@ -1190,20 +1194,20 @@ function or(r, e, t) {
1190
1194
  j,
1191
1195
  L,
1192
1196
  R,
1193
- v,
1197
+ w,
1194
1198
  h,
1195
1199
  y,
1196
1200
  ie,
1197
1201
  u,
1198
1202
  d,
1199
1203
  z,
1200
- ge,
1201
- Me,
1202
- fe,
1204
+ ve,
1205
+ Ue,
1206
+ de,
1203
1207
  q,
1204
1208
  o,
1205
- mt,
1206
1209
  bt,
1210
+ vt,
1207
1211
  wt
1208
1212
  ];
1209
1213
  }
@@ -1250,133 +1254,133 @@ class lr extends Bt {
1250
1254
  return this.$$.ctx[0];
1251
1255
  }
1252
1256
  set auto(e) {
1253
- this.$$set({ auto: e }), w();
1257
+ this.$$set({ auto: e }), v();
1254
1258
  }
1255
1259
  get blockspam() {
1256
1260
  return this.$$.ctx[27];
1257
1261
  }
1258
1262
  set blockspam(e) {
1259
- this.$$set({ blockspam: e }), w();
1263
+ this.$$set({ blockspam: e }), v();
1260
1264
  }
1261
1265
  get challengeurl() {
1262
1266
  return this.$$.ctx[14];
1263
1267
  }
1264
1268
  set challengeurl(e) {
1265
- this.$$set({ challengeurl: e }), w();
1269
+ this.$$set({ challengeurl: e }), v();
1266
1270
  }
1267
1271
  get challengejson() {
1268
1272
  return this.$$.ctx[28];
1269
1273
  }
1270
1274
  set challengejson(e) {
1271
- this.$$set({ challengejson: e }), w();
1275
+ this.$$set({ challengejson: e }), v();
1272
1276
  }
1273
1277
  get debug() {
1274
1278
  return this.$$.ctx[15];
1275
1279
  }
1276
1280
  set debug(e) {
1277
- this.$$set({ debug: e }), w();
1281
+ this.$$set({ debug: e }), v();
1278
1282
  }
1279
1283
  get delay() {
1280
1284
  return this.$$.ctx[16];
1281
1285
  }
1282
1286
  set delay(e) {
1283
- this.$$set({ delay: e }), w();
1287
+ this.$$set({ delay: e }), v();
1284
1288
  }
1285
1289
  get expire() {
1286
1290
  return this.$$.ctx[17];
1287
1291
  }
1288
1292
  set expire(e) {
1289
- this.$$set({ expire: e }), w();
1293
+ this.$$set({ expire: e }), v();
1290
1294
  }
1291
1295
  get floating() {
1292
1296
  return this.$$.ctx[1];
1293
1297
  }
1294
1298
  set floating(e) {
1295
- this.$$set({ floating: e }), w();
1299
+ this.$$set({ floating: e }), v();
1296
1300
  }
1297
1301
  get floatinganchor() {
1298
1302
  return this.$$.ctx[18];
1299
1303
  }
1300
1304
  set floatinganchor(e) {
1301
- this.$$set({ floatinganchor: e }), w();
1305
+ this.$$set({ floatinganchor: e }), v();
1302
1306
  }
1303
1307
  get floatingoffset() {
1304
1308
  return this.$$.ctx[19];
1305
1309
  }
1306
1310
  set floatingoffset(e) {
1307
- this.$$set({ floatingoffset: e }), w();
1311
+ this.$$set({ floatingoffset: e }), v();
1308
1312
  }
1309
1313
  get hidefooter() {
1310
1314
  return this.$$.ctx[2];
1311
1315
  }
1312
1316
  set hidefooter(e) {
1313
- this.$$set({ hidefooter: e }), w();
1317
+ this.$$set({ hidefooter: e }), v();
1314
1318
  }
1315
1319
  get hidelogo() {
1316
1320
  return this.$$.ctx[3];
1317
1321
  }
1318
1322
  set hidelogo(e) {
1319
- this.$$set({ hidelogo: e }), w();
1323
+ this.$$set({ hidelogo: e }), v();
1320
1324
  }
1321
1325
  get name() {
1322
1326
  return this.$$.ctx[4];
1323
1327
  }
1324
1328
  set name(e) {
1325
- this.$$set({ name: e }), w();
1329
+ this.$$set({ name: e }), v();
1326
1330
  }
1327
1331
  get maxnumber() {
1328
1332
  return this.$$.ctx[20];
1329
1333
  }
1330
1334
  set maxnumber(e) {
1331
- this.$$set({ maxnumber: e }), w();
1335
+ this.$$set({ maxnumber: e }), v();
1332
1336
  }
1333
1337
  get mockerror() {
1334
1338
  return this.$$.ctx[21];
1335
1339
  }
1336
1340
  set mockerror(e) {
1337
- this.$$set({ mockerror: e }), w();
1341
+ this.$$set({ mockerror: e }), v();
1338
1342
  }
1339
1343
  get refetchonexpire() {
1340
1344
  return this.$$.ctx[22];
1341
1345
  }
1342
1346
  set refetchonexpire(e) {
1343
- this.$$set({ refetchonexpire: e }), w();
1347
+ this.$$set({ refetchonexpire: e }), v();
1344
1348
  }
1345
1349
  get spamfilter() {
1346
1350
  return this.$$.ctx[23];
1347
1351
  }
1348
1352
  set spamfilter(e) {
1349
- this.$$set({ spamfilter: e }), w();
1353
+ this.$$set({ spamfilter: e }), v();
1350
1354
  }
1351
1355
  get strings() {
1352
1356
  return this.$$.ctx[29];
1353
1357
  }
1354
1358
  set strings(e) {
1355
- this.$$set({ strings: e }), w();
1359
+ this.$$set({ strings: e }), v();
1356
1360
  }
1357
1361
  get test() {
1358
1362
  return this.$$.ctx[24];
1359
1363
  }
1360
1364
  set test(e) {
1361
- this.$$set({ test: e }), w();
1365
+ this.$$set({ test: e }), v();
1362
1366
  }
1363
1367
  get verifyurl() {
1364
1368
  return this.$$.ctx[25];
1365
1369
  }
1366
1370
  set verifyurl(e) {
1367
- this.$$set({ verifyurl: e }), w();
1371
+ this.$$set({ verifyurl: e }), v();
1368
1372
  }
1369
1373
  get workers() {
1370
1374
  return this.$$.ctx[26];
1371
1375
  }
1372
1376
  set workers(e) {
1373
- this.$$set({ workers: e }), w();
1377
+ this.$$set({ workers: e }), v();
1374
1378
  }
1375
1379
  get workerurl() {
1376
1380
  return this.$$.ctx[30];
1377
1381
  }
1378
1382
  set workerurl(e) {
1379
- this.$$set({ workerurl: e }), w();
1383
+ this.$$set({ workerurl: e }), v();
1380
1384
  }
1381
1385
  get configure() {
1382
1386
  return this.$$.ctx[31];