@getauthui/core 0.1.9 → 0.1.11

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.
@@ -1,7 +1,7 @@
1
- import { state as d, property as g, customElement as T, query as st } from "lit/decorators.js";
2
- import { css as O, LitElement as rt, nothing as n, html as r, svg as h } from "lit";
3
- import { Client as lt, Account as ct, Teams as xt, ID as B, Avatars as kt } from "appwrite";
4
- const Ct = {
1
+ import { state as c, property as m, customElement as T, query as at } from "lit/decorators.js";
2
+ import { css as L, LitElement as nt, nothing as n, html as r, svg as u } from "lit";
3
+ import { Client as ct, Account as dt, Teams as kt, ID as W, Avatars as Ct } from "appwrite";
4
+ const St = {
5
5
  signIn: "Sign in",
6
6
  dialogSignIn: "Sign in",
7
7
  signUp: "Sign up",
@@ -171,15 +171,17 @@ const Ct = {
171
171
  lastActive: "Last active",
172
172
  guestAccount: "Guest account",
173
173
  guestAccountDescription: "Add an email and password to keep your data.",
174
- preview: "Preview"
174
+ preview: "Preview",
175
+ acceptLegal: "I agree to the",
176
+ errorLegalRequired: "Accept the terms to continue."
175
177
  };
176
- function St(e, t = {}) {
178
+ function At(e, t = {}) {
177
179
  return e.replace(
178
180
  /\{(\w+)\}/g,
179
181
  (i, s) => s in t ? String(t[s]) : `{${s}}`
180
182
  );
181
183
  }
182
- const At = {
184
+ const Pt = {
183
185
  amazon: "Amazon",
184
186
  apple: "Apple",
185
187
  appwrite: "Appwrite",
@@ -230,10 +232,10 @@ const At = {
230
232
  zoho: "Zoho",
231
233
  zoom: "Zoom"
232
234
  };
233
- function W(e) {
234
- return At[e] ?? e.charAt(0).toUpperCase() + e.slice(1);
235
+ function N(e) {
236
+ return Pt[e] ?? e.charAt(0).toUpperCase() + e.slice(1);
235
237
  }
236
- const H = (e, t, i = 401) => Object.assign(new Error(t), { type: e, code: i }), A = () => (/* @__PURE__ */ new Date()).toISOString(), U = (e) => new Date(Date.now() - e * 6e4).toISOString(), j = [
238
+ const K = (e, t, i = 401) => Object.assign(new Error(t), { type: e, code: i }), P = () => (/* @__PURE__ */ new Date()).toISOString(), M = (e) => new Date(Date.now() - e * 6e4).toISOString(), G = [
237
239
  "amber",
238
240
  "brave",
239
241
  "calm",
@@ -246,13 +248,13 @@ const H = (e, t, i = 401) => Object.assign(new Error(t), { type: e, code: i }),
246
248
  "juniper",
247
249
  "kite",
248
250
  "lumen"
249
- ], dt = () => `${j[Math.floor(Math.random() * j.length)]}-${j[Math.floor(Math.random() * j.length)]}`, D = () => Math.random().toString(36).slice(2, 12), ht = () => Array.from({ length: 2 }, () => Math.random().toString(36).slice(2, 7)).join("-"), Pt = {
251
+ ], ht = () => `${G[Math.floor(Math.random() * G.length)]}-${G[Math.floor(Math.random() * G.length)]}`, D = () => Math.random().toString(36).slice(2, 12), ut = () => Array.from({ length: 2 }, () => Math.random().toString(36).slice(2, 7)).join("-"), Et = {
250
252
  name: "Ada Lovelace",
251
253
  email: "ada@example.com",
252
254
  phone: "+15550100"
253
255
  };
254
256
  class It {
255
- constructor(t = Pt) {
257
+ constructor(t = Et) {
256
258
  this.seed = t, this.user = null, this.mfaPending = !1, this.mfaEnabled = !1, this.totpEnrolled = !1, this.recoveryCodes = [], this.lastChallenge = 0, this.sessions = [], this.identities = [], this.logs = [], this.tokens = /* @__PURE__ */ new Map(), this.pendingAuthenticator = null;
257
259
  }
258
260
  // ───────────────────────── helpers ─────────────────────────
@@ -260,13 +262,13 @@ class It {
260
262
  const i = t.anonymous ?? !1;
261
263
  return this.user = {
262
264
  $id: "preview-user",
263
- $createdAt: U(1440 * 30),
264
- $updatedAt: A(),
265
+ $createdAt: M(1440 * 30),
266
+ $updatedAt: P(),
265
267
  name: i ? "" : t.name ?? this.seed.name,
266
- registration: U(1440 * 30),
268
+ registration: M(1440 * 30),
267
269
  status: !0,
268
270
  labels: [],
269
- passwordUpdate: i ? "" : U(1440 * 7),
271
+ passwordUpdate: i ? "" : M(1440 * 7),
270
272
  email: i ? "" : t.email ?? this.seed.email,
271
273
  phone: i ? "" : t.phone ?? this.seed.phone,
272
274
  emailVerification: !i,
@@ -274,14 +276,14 @@ class It {
274
276
  mfa: this.mfaEnabled,
275
277
  prefs: {},
276
278
  targets: [],
277
- accessedAt: A()
279
+ accessedAt: P()
278
280
  }, this.seedActivity(i ? "anonymous" : "email"), this.user;
279
281
  }
280
282
  seedActivity(t) {
281
283
  if (this.sessions.length > 0) return;
282
284
  const i = {
283
- $createdAt: A(),
284
- $updatedAt: A(),
285
+ $createdAt: P(),
286
+ $updatedAt: P(),
285
287
  userId: "preview-user",
286
288
  expire: new Date(Date.now() + 365 * 864e5).toISOString(),
287
289
  providerUid: "",
@@ -317,7 +319,7 @@ class It {
317
319
  {
318
320
  ...i,
319
321
  $id: D(),
320
- $createdAt: U(300),
322
+ $createdAt: M(300),
321
323
  provider: t,
322
324
  ip: "198.51.100.7",
323
325
  osCode: "IOS",
@@ -334,7 +336,7 @@ class It {
334
336
  {
335
337
  ...i,
336
338
  $id: D(),
337
- $createdAt: U(1440 * 3),
339
+ $createdAt: M(1440 * 3),
338
340
  provider: "oauth2",
339
341
  ip: "192.0.2.90",
340
342
  osCode: "WIN",
@@ -349,8 +351,8 @@ class It {
349
351
  ], this.identities = [
350
352
  {
351
353
  $id: "identity-github",
352
- $createdAt: U(1440 * 20),
353
- $updatedAt: U(1440 * 20),
354
+ $createdAt: M(1440 * 20),
355
+ $updatedAt: M(1440 * 20),
354
356
  userId: "preview-user",
355
357
  provider: "github",
356
358
  providerUid: "8675309",
@@ -362,7 +364,7 @@ class It {
362
364
  ], this.logs = [
363
365
  {
364
366
  event: "session.create",
365
- time: A(),
367
+ time: P(),
366
368
  clientName: "Chrome",
367
369
  osName: "macOS",
368
370
  countryName: "Germany",
@@ -370,7 +372,7 @@ class It {
370
372
  },
371
373
  {
372
374
  event: "user.update.name",
373
- time: U(1440 * 2),
375
+ time: M(1440 * 2),
374
376
  clientName: "Safari",
375
377
  osName: "iOS",
376
378
  countryName: "Germany",
@@ -378,7 +380,7 @@ class It {
378
380
  },
379
381
  {
380
382
  event: "session.create",
381
- time: U(1440 * 3),
383
+ time: M(1440 * 3),
382
384
  clientName: "Firefox",
383
385
  osName: "Windows",
384
386
  countryName: "United States",
@@ -388,9 +390,9 @@ class It {
388
390
  }
389
391
  requireUser() {
390
392
  if (!this.user)
391
- throw H("general_unauthorized_scope", "User (role: guests) missing scope (account)");
393
+ throw K("general_unauthorized_scope", "User (role: guests) missing scope (account)");
392
394
  if (this.mfaPending)
393
- throw H(
395
+ throw K(
394
396
  "user_more_factors_required",
395
397
  "More factors are required to complete the sign in process."
396
398
  );
@@ -398,7 +400,7 @@ class It {
398
400
  }
399
401
  requireRecentChallenge() {
400
402
  if (Date.now() - this.lastChallenge > 30 * 6e4)
401
- throw H(
403
+ throw K(
402
404
  "user_challenge_required",
403
405
  "A recently successful challenge is required to complete this action."
404
406
  );
@@ -435,25 +437,25 @@ class It {
435
437
  async createMagicURLToken(t, i) {
436
438
  return this.tokens.set(t, { email: i }), this.delay({
437
439
  $id: D(),
438
- $createdAt: A(),
440
+ $createdAt: P(),
439
441
  userId: t,
440
442
  secret: "",
441
443
  expire: "",
442
- phrase: dt()
444
+ phrase: ht()
443
445
  });
444
446
  }
445
447
  async createEmailToken(t, i) {
446
448
  return this.tokens.set(t, { email: i }), this.delay({
447
449
  $id: D(),
448
- $createdAt: A(),
450
+ $createdAt: P(),
449
451
  userId: t,
450
452
  secret: "",
451
453
  expire: "",
452
- phrase: dt()
454
+ phrase: ht()
453
455
  });
454
456
  }
455
457
  async createPhoneToken(t, i) {
456
- return this.tokens.set(t, { phone: i }), this.delay({ $id: D(), $createdAt: A(), userId: t, secret: "", expire: "", phrase: "" });
458
+ return this.tokens.set(t, { phone: i }), this.delay({ $id: D(), $createdAt: P(), userId: t, secret: "", expire: "", phrase: "" });
457
459
  }
458
460
  async createSession(t) {
459
461
  return this.delay(() => {
@@ -494,7 +496,7 @@ class It {
494
496
  async updateEmail(t) {
495
497
  return this.delay(() => {
496
498
  const i = this.requireUser();
497
- return i.email = t, i.emailVerification = !1, i.passwordUpdate = A(), i;
499
+ return i.email = t, i.emailVerification = !1, i.passwordUpdate = P(), i;
498
500
  });
499
501
  }
500
502
  async updatePhone(t) {
@@ -506,7 +508,7 @@ class It {
506
508
  async updatePassword() {
507
509
  return this.delay(() => {
508
510
  const t = this.requireUser();
509
- return t.passwordUpdate = A(), t;
511
+ return t.passwordUpdate = P(), t;
510
512
  });
511
513
  }
512
514
  async updateStatus() {
@@ -545,7 +547,7 @@ class It {
545
547
  });
546
548
  }
547
549
  async createMFAChallenge() {
548
- return this.delay({ $id: D(), $createdAt: A(), userId: "preview-user", expire: "" });
550
+ return this.delay({ $id: D(), $createdAt: P(), userId: "preview-user", expire: "" });
549
551
  }
550
552
  async updateMFAChallenge() {
551
553
  return this.delay(() => (this.mfaPending = !1, this.lastChallenge = Date.now(), this.sessions[0]));
@@ -574,35 +576,35 @@ class It {
574
576
  async createMFARecoveryCodes() {
575
577
  return this.delay(() => {
576
578
  if (this.recoveryCodes.length > 0)
577
- throw H("user_recovery_codes_already_exists", "Recovery codes already generated.", 409);
578
- return this.recoveryCodes = Array.from({ length: 6 }, ht), { recoveryCodes: this.recoveryCodes };
579
+ throw K("user_recovery_codes_already_exists", "Recovery codes already generated.", 409);
580
+ return this.recoveryCodes = Array.from({ length: 6 }, ut), { recoveryCodes: this.recoveryCodes };
579
581
  });
580
582
  }
581
583
  async getMFARecoveryCodes() {
582
584
  return this.delay(() => (this.requireRecentChallenge(), { recoveryCodes: this.recoveryCodes }));
583
585
  }
584
586
  async updateMFARecoveryCodes() {
585
- return this.delay(() => (this.requireRecentChallenge(), this.recoveryCodes = Array.from({ length: 6 }, ht), { recoveryCodes: this.recoveryCodes }));
587
+ return this.delay(() => (this.requireRecentChallenge(), this.recoveryCodes = Array.from({ length: 6 }, ut), { recoveryCodes: this.recoveryCodes }));
586
588
  }
587
589
  /** Forget everything, as a sign out would. */
588
590
  reset() {
589
591
  this.user = null, this.mfaPending = !1, this.sessions = [], this.identities = [], this.logs = [], this.tokens.clear();
590
592
  }
591
593
  }
592
- function Et(e) {
594
+ function Ut(e) {
593
595
  let t = 2166136261;
594
596
  const i = () => (t ^= t << 13, t ^= t >>> 17, t ^= t << 5, (t >>> 0) / 4294967296);
595
- for (const b of e) t = (t ^ b.charCodeAt(0)) * 16777619;
597
+ for (const g of e) t = (t ^ g.charCodeAt(0)) * 16777619;
596
598
  const s = 25;
597
599
  let a = "";
598
- const c = (b, $) => `<rect x="${b}" y="${$}" width="7" height="7"/><rect x="${b + 1}" y="${$ + 1}" width="5" height="5" fill="#fff"/><rect x="${b + 2}" y="${$ + 2}" width="3" height="3"/>`;
599
- for (let b = 0; b < s; b++)
600
- for (let $ = 0; $ < s; $++)
601
- !($ < 8 && b < 8 || $ >= s - 8 && b < 8 || $ < 8 && b >= s - 8) && i() < 0.45 && (a += `<rect x="${$}" y="${b}" width="1" height="1"/>`);
602
- const u = `<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 ${s} ${s}" shape-rendering="crispEdges"><rect width="${s}" height="${s}" fill="#fff"/><g fill="#000">${c(0, 0)}${c(s - 7, 0)}${c(0, s - 7)}${a}</g></svg>`;
603
- return `data:image/svg+xml;utf8,${encodeURIComponent(u)}`;
600
+ const h = (g, y) => `<rect x="${g}" y="${y}" width="7" height="7"/><rect x="${g + 1}" y="${y + 1}" width="5" height="5" fill="#fff"/><rect x="${g + 2}" y="${y + 2}" width="3" height="3"/>`;
601
+ for (let g = 0; g < s; g++)
602
+ for (let y = 0; y < s; y++)
603
+ !(y < 8 && g < 8 || y >= s - 8 && g < 8 || y < 8 && g >= s - 8) && i() < 0.45 && (a += `<rect x="${y}" y="${g}" width="1" height="1"/>`);
604
+ const d = `<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 ${s} ${s}" shape-rendering="crispEdges"><rect width="${s}" height="${s}" fill="#fff"/><g fill="#000">${h(0, 0)}${h(s - 7, 0)}${h(0, s - 7)}${a}</g></svg>`;
605
+ return `data:image/svg+xml;utf8,${encodeURIComponent(d)}`;
604
606
  }
605
- const f = {
607
+ const v = {
606
608
  moreFactorsRequired: "user_more_factors_required",
607
609
  invalidCredentials: "user_invalid_credentials",
608
610
  userAlreadyExists: "user_already_exists",
@@ -637,7 +639,7 @@ const f = {
637
639
  targetAlreadyExists: "user_target_already_exists",
638
640
  argumentInvalid: "general_argument_invalid"
639
641
  };
640
- function _(e) {
642
+ function q(e) {
641
643
  if (e && typeof e == "object") {
642
644
  const t = e;
643
645
  let i = typeof t.message == "string" ? t.message : "Unknown error";
@@ -649,80 +651,80 @@ function _(e) {
649
651
  }
650
652
  return { message: String(e), type: "", code: 0 };
651
653
  }
652
- function q(e, t) {
653
- return _(e).type === t;
654
+ function j(e, t) {
655
+ return q(e).type === t;
654
656
  }
655
- function K(e, t, i = "link") {
656
- const s = _(e);
657
+ function Y(e, t, i = "link") {
658
+ const s = q(e);
657
659
  switch (s.type) {
658
- case f.invalidCredentials:
660
+ case v.invalidCredentials:
659
661
  return i === "password" ? t.errorCurrentPassword : t.errorInvalidCredentials;
660
- case f.userAlreadyExists:
661
- case f.emailAlreadyExists:
662
- case f.phoneAlreadyExists:
662
+ case v.userAlreadyExists:
663
+ case v.emailAlreadyExists:
664
+ case v.phoneAlreadyExists:
663
665
  return t.errorUserExists;
664
- case f.userBlocked:
666
+ case v.userBlocked:
665
667
  return t.errorUserBlocked;
666
- case f.rateLimit:
668
+ case v.rateLimit:
667
669
  return t.errorRateLimit;
668
- case f.invalidToken:
670
+ case v.invalidToken:
669
671
  return i === "code" ? t.errorInvalidCode : t.errorInvalidToken;
670
- case f.invalidCode:
672
+ case v.invalidCode:
671
673
  return t.errorInvalidCode;
672
- case f.passwordMismatch:
674
+ case v.passwordMismatch:
673
675
  return t.errorPasswordMismatch;
674
- case f.passwordRecentlyUsed:
676
+ case v.passwordRecentlyUsed:
675
677
  return t.errorPasswordRecentlyUsed;
676
- case f.passwordPersonalData:
678
+ case v.passwordPersonalData:
677
679
  return t.errorPasswordPersonalData;
678
- case f.passwordWeak:
680
+ case v.passwordWeak:
679
681
  return t.errorPasswordWeak;
680
- case f.passwordPwned:
682
+ case v.passwordPwned:
681
683
  return t.errorPasswordPwned;
682
- case f.challengeRequired:
684
+ case v.challengeRequired:
683
685
  return t.errorChallengeRequired;
684
- case f.sessionAlreadyExists:
686
+ case v.sessionAlreadyExists:
685
687
  return t.errorSessionExists;
686
- case f.oauthUnauthorized:
687
- case f.oauthBadRequest:
688
+ case v.oauthUnauthorized:
689
+ case v.oauthBadRequest:
688
690
  return t.errorOAuth;
689
- case f.authMethodUnsupported:
691
+ case v.authMethodUnsupported:
690
692
  return t.errorMethodDisabled;
691
693
  }
692
- if (s.type === f.argumentInvalid || /Invalid `\w+` param/i.test(s.message)) {
694
+ if (s.type === v.argumentInvalid || /Invalid `\w+` param/i.test(s.message)) {
693
695
  const a = s.message.match(/Invalid `([^`]+)` param/i)?.[1]?.toLowerCase();
694
696
  return a === "email" ? t.errorInvalidEmail : a === "password" ? t.errorInvalidPassword : a === "phone" ? t.errorInvalidPhone : a === "name" ? t.errorInvalidName : t.errorGeneric;
695
697
  }
696
- return s.type === f.projectNotFound || s.type === f.unknownOrigin ? t.errorConfig : s.type === f.routeNotFound ? t.errorConfigEndpoint : s.code === 0 && /fetch|network/i.test(s.message) ? t.errorNetwork : /Invalid `\w+` param/i.test(s.message) ? t.errorGeneric : s.message ? s.message || t.errorGeneric : s.code === 404 || s.type === f.routeNotFound ? t.errorConfigEndpoint : t.errorGeneric;
698
+ return s.type === v.projectNotFound || s.type === v.unknownOrigin ? t.errorConfig : s.type === v.routeNotFound ? t.errorConfigEndpoint : s.code === 0 && /fetch|network/i.test(s.message) ? t.errorNetwork : /Invalid `\w+` param/i.test(s.message) ? t.errorGeneric : s.message ? s.message || t.errorGeneric : s.code === 404 || s.type === v.routeNotFound ? t.errorConfigEndpoint : t.errorGeneric;
697
699
  }
698
- function Ut(e) {
699
- const t = _(e);
700
- return !!(t.type === f.projectNotFound || t.type === f.unknownOrigin || t.type === f.routeNotFound || !t.message && t.code === 404 || t.code === 0 && /fetch|network|load failed|failed to fetch/i.test(t.message));
700
+ function Mt(e) {
701
+ const t = q(e);
702
+ return !!(t.type === v.projectNotFound || t.type === v.unknownOrigin || t.type === v.routeNotFound || !t.message && t.code === 404 || t.code === 0 && /fetch|network|load failed|failed to fetch/i.test(t.message));
701
703
  }
702
- const J = (e) => `authui:active-team:${e}`;
703
- function ut(e) {
704
+ const et = (e) => `authui:active-team:${e}`;
705
+ function pt(e) {
704
706
  if (typeof localStorage > "u" || !e) return null;
705
707
  try {
706
- return localStorage.getItem(J(e));
708
+ return localStorage.getItem(et(e));
707
709
  } catch {
708
710
  return null;
709
711
  }
710
712
  }
711
- function Mt(e, t) {
713
+ function Ot(e, t) {
712
714
  if (!(typeof localStorage > "u" || !e))
713
715
  try {
714
- t ? localStorage.setItem(J(e), t) : localStorage.removeItem(J(e));
716
+ t ? localStorage.setItem(et(e), t) : localStorage.removeItem(et(e));
715
717
  } catch {
716
718
  }
717
719
  }
718
- const at = "authui:last-method";
719
- function V(e) {
720
+ const ot = "authui:last-method";
721
+ function _(e) {
720
722
  if (!(typeof localStorage > "u")) {
721
723
  if (!e || e === "mfa" || e === "sign-up")
722
724
  if (e === "sign-up") e = "email-password";
723
725
  else return;
724
726
  try {
725
- localStorage.setItem(at, e);
727
+ localStorage.setItem(ot, e);
726
728
  } catch {
727
729
  }
728
730
  }
@@ -730,42 +732,42 @@ function V(e) {
730
732
  function z() {
731
733
  if (typeof localStorage > "u") return null;
732
734
  try {
733
- return localStorage.getItem(at);
735
+ return localStorage.getItem(ot);
734
736
  } catch {
735
737
  return null;
736
738
  }
737
739
  }
738
- function oe() {
740
+ function le() {
739
741
  if (!(typeof localStorage > "u"))
740
742
  try {
741
- localStorage.removeItem(at);
743
+ localStorage.removeItem(ot);
742
744
  } catch {
743
745
  }
744
746
  }
745
- const G = "authui:pending-oauth";
746
- function Ot(e) {
747
+ const Z = "authui:pending-oauth";
748
+ function Ft(e) {
747
749
  if (!(typeof sessionStorage > "u"))
748
750
  try {
749
- sessionStorage.setItem(G, e);
751
+ sessionStorage.setItem(Z, e);
750
752
  } catch {
751
753
  }
752
754
  }
753
- function wt() {
755
+ function $t() {
754
756
  if (!(typeof sessionStorage > "u"))
755
757
  try {
756
- const e = sessionStorage.getItem(G);
757
- sessionStorage.removeItem(G), e && V(`oauth:${e}`);
758
+ const e = sessionStorage.getItem(Z);
759
+ sessionStorage.removeItem(Z), e && _(`oauth:${e}`);
758
760
  } catch {
759
761
  }
760
762
  }
761
- function pt() {
763
+ function mt() {
762
764
  if (!(typeof sessionStorage > "u"))
763
765
  try {
764
- sessionStorage.removeItem(G);
766
+ sessionStorage.removeItem(Z);
765
767
  } catch {
766
768
  }
767
769
  }
768
- function S(e, t, i) {
770
+ function A(e, t, i) {
769
771
  for (const s of t) {
770
772
  const a = e[s];
771
773
  if (typeof a == "function")
@@ -775,7 +777,7 @@ function S(e, t, i) {
775
777
  new Error(`Appwrite SDK is missing ${t[0]}(). Update the appwrite package.`)
776
778
  );
777
779
  }
778
- const tt = "authui", mt = ["userId", "secret", "expire", "project", "error", tt], ft = () => ({
780
+ const it = "authui", ft = ["userId", "secret", "expire", "project", "error", it], gt = () => ({
779
781
  status: "loading",
780
782
  user: null,
781
783
  mfaFactors: null,
@@ -783,9 +785,9 @@ const tt = "authui", mt = ["userId", "secret", "expire", "project", "error", tt]
783
785
  configured: !1,
784
786
  configError: null
785
787
  });
786
- class Ft {
788
+ class Lt {
787
789
  constructor() {
788
- this.client = null, this.account = null, this.config = null, this.state = ft(), this.listeners = /* @__PURE__ */ new Map(), this.refreshPromise = null, this.preview = null, this.teams = null, this.activeTeamId = null;
790
+ this.client = null, this.account = null, this.config = null, this.state = gt(), this.listeners = /* @__PURE__ */ new Map(), this.refreshPromise = null, this.preview = null, this.teams = null, this.activeTeamId = null;
789
791
  }
790
792
  // ───────────────────────────── configuration ─────────────────────────────
791
793
  /** Configure the Appwrite client. Safe to call more than once; the last call wins. */
@@ -793,7 +795,7 @@ class Ft {
793
795
  const i = t.endpoint.trim().replace(/\/+$/, "");
794
796
  i && !i.endsWith("/v1") && console.warn(
795
797
  `[authui] endpoint should end with /v1 (got "${t.endpoint}"). Without it Appwrite returns HTML 404 pages.`
796
- ), this.config = t, this.client = new lt().setEndpoint(t.endpoint).setProject(t.project), this.preview = t.preview ? new It() : null, this.account = this.preview ? this.preview : new ct(this.client), this.teams = null, this.activeTeamId = ut(t.project), this.setState({ configured: !0, status: "loading", configError: null }), this.preview ? this.refresh() : typeof window < "u" && this.handleRedirect().then(() => this.refresh());
798
+ ), this.config = t, this.client = new ct().setEndpoint(t.endpoint).setProject(t.project), this.preview = t.preview ? new It() : null, this.account = this.preview ? this.preview : new dt(this.client), this.teams = null, this.activeTeamId = pt(t.project), this.setState({ configured: !0, status: "loading", configError: null }), this.preview ? this.refresh() : typeof window < "u" && this.handleRedirect().then(() => this.refresh());
797
799
  }
798
800
  /**
799
801
  * Called by <authui-config> when it is on the page but missing endpoint or project.
@@ -839,7 +841,7 @@ class Ft {
839
841
  /** List teams the signed-in user belongs to. Empty in preview or when signed out. */
840
842
  async listTeams() {
841
843
  if (this.preview || !this.client || this.state.status !== "signed-in") return [];
842
- this.teams ??= new xt(this.client);
844
+ this.teams ??= new kt(this.client);
843
845
  try {
844
846
  return (await this.teams.list()).teams ?? [];
845
847
  } catch (t) {
@@ -849,7 +851,7 @@ class Ft {
849
851
  getActiveTeamId() {
850
852
  if (this.activeTeamId) return this.activeTeamId;
851
853
  const t = this.config?.project;
852
- return t ? (this.activeTeamId = ut(t), this.activeTeamId) : null;
854
+ return t ? (this.activeTeamId = pt(t), this.activeTeamId) : null;
853
855
  }
854
856
  /**
855
857
  * Remember the active team locally and emit `active-team`.
@@ -857,10 +859,10 @@ class Ft {
857
859
  */
858
860
  setActiveTeam(t) {
859
861
  const i = this.config?.project;
860
- i && Mt(i, t?.$id ?? null), this.activeTeamId = t?.$id ?? null, this.emit("active-team", { teamId: this.activeTeamId, team: t });
862
+ i && Ot(i, t?.$id ?? null), this.activeTeamId = t?.$id ?? null, this.emit("active-team", { teamId: this.activeTeamId, team: t });
861
863
  }
862
864
  getStrings() {
863
- return { ...Ct, ...this.config?.strings ?? {} };
865
+ return { ...St, ...this.config?.strings ?? {} };
864
866
  }
865
867
  getState() {
866
868
  return { ...this.state };
@@ -886,7 +888,7 @@ class Ft {
886
888
  this.state = { ...this.state, ...t }, this.emit("change", this.getState());
887
889
  }
888
890
  fail(t) {
889
- const i = _(t);
891
+ const i = q(t);
890
892
  throw this.emit("error", i), t;
891
893
  }
892
894
  acct() {
@@ -906,10 +908,10 @@ class Ft {
906
908
  const i = await this.account.get();
907
909
  this.setState({ status: "signed-in", user: i, mfaFactors: null, configError: null }), t || this.emit("signed-in", i);
908
910
  } catch (i) {
909
- if (q(i, f.moreFactorsRequired)) {
911
+ if (j(i, v.moreFactorsRequired)) {
910
912
  let s = null;
911
913
  try {
912
- s = await S(
914
+ s = await A(
913
915
  this.account,
914
916
  ["listMFAFactors", "listMfaFactors"],
915
917
  []
@@ -917,7 +919,7 @@ class Ft {
917
919
  } catch {
918
920
  }
919
921
  this.setState({ status: "mfa-required", user: null, mfaFactors: s });
920
- } else if (q(i, f.userBlocked))
922
+ } else if (j(i, v.userBlocked))
921
923
  await this.purgeLocalSession(), this.setState({
922
924
  status: "signed-out",
923
925
  user: null,
@@ -928,13 +930,13 @@ class Ft {
928
930
  message: this.getStrings().errorUserBlocked
929
931
  }
930
932
  }), t && this.emit("signed-out", void 0);
931
- else if (!t && Ut(i)) {
932
- const a = K(i, this.getStrings()) || this.getStrings().errorConfig;
933
+ else if (!t && Mt(i)) {
934
+ const a = Y(i, this.getStrings()) || this.getStrings().errorConfig;
933
935
  console.warn(
934
936
  `[authui] ${a} (endpoint=${this.config?.endpoint ?? "?"}, project=${this.config?.project ?? "?"})`
935
937
  );
936
- const c = _(i);
937
- this.emit("error", { message: a, type: c.type, code: c.code }), this.setState({
938
+ const h = q(i);
939
+ this.emit("error", { message: a, type: h.type, code: h.code }), this.setState({
938
940
  status: "signed-out",
939
941
  user: null,
940
942
  mfaFactors: null,
@@ -953,7 +955,7 @@ class Ft {
953
955
  const i = this.state.pending;
954
956
  if (i?.type === "notice" && i.tone === "error")
955
957
  throw Object.assign(new Error(i.message), {
956
- type: f.userBlocked,
958
+ type: v.userBlocked,
957
959
  code: 401
958
960
  });
959
961
  }
@@ -978,7 +980,7 @@ class Ft {
978
980
  localStorage.removeItem("cookieFallback");
979
981
  } catch {
980
982
  }
981
- this.config && !this.preview && (this.client = new lt().setEndpoint(this.config.endpoint).setProject(this.config.project), this.account = new ct(this.client));
983
+ this.config && !this.preview && (this.client = new ct().setEndpoint(this.config.endpoint).setProject(this.config.project), this.account = new dt(this.client));
982
984
  }
983
985
  // ─────────────────────────────── sign in ───────────────────────────────
984
986
  async signInWithEmailPassword(t, i) {
@@ -991,7 +993,7 @@ class Ft {
991
993
  }
992
994
  async signUp(t, i, s) {
993
995
  try {
994
- await this.acct().create(B.unique(), t.trim(), i, s?.trim() || void 0), await this.acct().createEmailPasswordSession(t.trim(), i);
996
+ await this.acct().create(W.unique(), t.trim(), i, s?.trim() || void 0), await this.acct().createEmailPasswordSession(t.trim(), i);
995
997
  } catch (a) {
996
998
  this.fail(a);
997
999
  }
@@ -1034,7 +1036,7 @@ class Ft {
1034
1036
  async sendMagicUrl(t) {
1035
1037
  try {
1036
1038
  return await this.acct().createMagicURLToken(
1037
- B.unique(),
1039
+ W.unique(),
1038
1040
  t.trim(),
1039
1041
  this.redirectUrl("magic-url"),
1040
1042
  this.config?.securityPhrase ?? !0
@@ -1046,7 +1048,7 @@ class Ft {
1046
1048
  async sendEmailOtp(t) {
1047
1049
  try {
1048
1050
  return await this.acct().createEmailToken(
1049
- B.unique(),
1051
+ W.unique(),
1050
1052
  t.trim(),
1051
1053
  this.config?.securityPhrase ?? !0
1052
1054
  );
@@ -1056,7 +1058,7 @@ class Ft {
1056
1058
  }
1057
1059
  async sendPhoneOtp(t) {
1058
1060
  try {
1059
- return await this.acct().createPhoneToken(B.unique(), t.replace(/[\s()-]/g, ""));
1061
+ return await this.acct().createPhoneToken(W.unique(), t.replace(/[\s()-]/g, ""));
1060
1062
  } catch (i) {
1061
1063
  return this.fail(i);
1062
1064
  }
@@ -1073,7 +1075,7 @@ class Ft {
1073
1075
  // ─────────────────────────────── MFA ───────────────────────────────
1074
1076
  async createMfaChallenge(t) {
1075
1077
  try {
1076
- return await S(
1078
+ return await A(
1077
1079
  this.acct(),
1078
1080
  ["createMFAChallenge", "createMfaChallenge"],
1079
1081
  [t]
@@ -1085,7 +1087,7 @@ class Ft {
1085
1087
  /** Verify a challenge. Completes a pending sign in, or acts as a step-up for protected actions. */
1086
1088
  async completeMfaChallenge(t, i, s = {}) {
1087
1089
  try {
1088
- await S(
1090
+ await A(
1089
1091
  this.acct(),
1090
1092
  ["updateMFAChallenge", "updateMfaChallenge"],
1091
1093
  [t, i.trim()]
@@ -1097,7 +1099,7 @@ class Ft {
1097
1099
  }
1098
1100
  async listMfaFactors() {
1099
1101
  try {
1100
- return await S(this.acct(), ["listMFAFactors", "listMfaFactors"], []);
1102
+ return await A(this.acct(), ["listMFAFactors", "listMfaFactors"], []);
1101
1103
  } catch (t) {
1102
1104
  return this.fail(t);
1103
1105
  }
@@ -1112,7 +1114,7 @@ class Ft {
1112
1114
  }
1113
1115
  async addAuthenticator() {
1114
1116
  try {
1115
- return await S(
1117
+ return await A(
1116
1118
  this.acct(),
1117
1119
  ["createMFAAuthenticator", "createMfaAuthenticator"],
1118
1120
  ["totp"]
@@ -1123,7 +1125,7 @@ class Ft {
1123
1125
  }
1124
1126
  async verifyAuthenticator(t) {
1125
1127
  try {
1126
- await S(
1128
+ await A(
1127
1129
  this.acct(),
1128
1130
  ["updateMFAAuthenticator", "updateMfaAuthenticator"],
1129
1131
  ["totp", t.trim()]
@@ -1136,7 +1138,7 @@ class Ft {
1136
1138
  /** Requires a recent MFA challenge (server rejects with user_challenge_required otherwise). */
1137
1139
  async removeAuthenticator() {
1138
1140
  try {
1139
- await S(this.acct(), ["deleteMFAAuthenticator", "deleteMfaAuthenticator"], ["totp"]);
1141
+ await A(this.acct(), ["deleteMFAAuthenticator", "deleteMfaAuthenticator"], ["totp"]);
1140
1142
  } catch (t) {
1141
1143
  this.fail(t);
1142
1144
  }
@@ -1144,7 +1146,7 @@ class Ft {
1144
1146
  }
1145
1147
  async createRecoveryCodes() {
1146
1148
  try {
1147
- return (await S(
1149
+ return (await A(
1148
1150
  this.acct(),
1149
1151
  ["createMFARecoveryCodes", "createMfaRecoveryCodes"],
1150
1152
  []
@@ -1156,7 +1158,7 @@ class Ft {
1156
1158
  /** Requires a recent MFA challenge. */
1157
1159
  async regenerateRecoveryCodes() {
1158
1160
  try {
1159
- return (await S(
1161
+ return (await A(
1160
1162
  this.acct(),
1161
1163
  ["updateMFARecoveryCodes", "updateMfaRecoveryCodes"],
1162
1164
  []
@@ -1168,7 +1170,7 @@ class Ft {
1168
1170
  /** Requires a recent MFA challenge. */
1169
1171
  async getRecoveryCodes() {
1170
1172
  try {
1171
- return (await S(
1173
+ return (await A(
1172
1174
  this.acct(),
1173
1175
  ["getMFARecoveryCodes", "getMfaRecoveryCodes"],
1174
1176
  []
@@ -1290,7 +1292,7 @@ class Ft {
1290
1292
  }
1291
1293
  async sendEmailVerification() {
1292
1294
  try {
1293
- await S(
1295
+ await A(
1294
1296
  this.acct(),
1295
1297
  ["createEmailVerification", "createVerification"],
1296
1298
  [this.redirectUrl("verify-email")]
@@ -1330,8 +1332,8 @@ class Ft {
1330
1332
  /** Build the URL Appwrite should send the user back to for a given flow. */
1331
1333
  redirectUrl(t) {
1332
1334
  const i = this.config?.redirectUrl ?? (typeof window < "u" ? window.location.origin + window.location.pathname : ""), s = new URL(i, typeof window < "u" ? window.location.href : void 0);
1333
- for (const a of mt) s.searchParams.delete(a);
1334
- return s.searchParams.set(tt, t), s.toString();
1335
+ for (const a of ft) s.searchParams.delete(a);
1336
+ return s.searchParams.set(it, t), s.toString();
1335
1337
  }
1336
1338
  setPending(t) {
1337
1339
  this.setState({ pending: t });
@@ -1342,11 +1344,11 @@ class Ft {
1342
1344
  */
1343
1345
  async handleRedirect() {
1344
1346
  if (typeof window > "u") return !1;
1345
- const t = new URLSearchParams(window.location.search), i = t.get(tt);
1347
+ const t = new URLSearchParams(window.location.search), i = t.get(it);
1346
1348
  if (!i) return !1;
1347
1349
  const s = t.get("userId") ?? "", a = t.get("secret") ?? "";
1348
1350
  this.cleanUrl();
1349
- const c = () => {
1351
+ const h = () => {
1350
1352
  this.setState({
1351
1353
  pending: {
1352
1354
  type: "notice",
@@ -1359,10 +1361,10 @@ class Ft {
1359
1361
  switch (i) {
1360
1362
  case "oauth":
1361
1363
  case "magic-url":
1362
- s && a ? (await this.acct().createSession(s, a), i === "oauth" && wt()) : (i === "oauth" && pt(), c());
1364
+ s && a ? (await this.acct().createSession(s, a), i === "oauth" ? $t() : _("magic-url")) : (i === "oauth" && mt(), h());
1363
1365
  break;
1364
1366
  case "oauth-failed":
1365
- pt(), this.setState({
1367
+ mt(), this.setState({
1366
1368
  pending: {
1367
1369
  type: "notice",
1368
1370
  tone: "error",
@@ -1371,10 +1373,10 @@ class Ft {
1371
1373
  });
1372
1374
  break;
1373
1375
  case "recovery":
1374
- s && a ? this.setState({ pending: { type: "reset-password", userId: s, secret: a } }) : c();
1376
+ s && a ? this.setState({ pending: { type: "reset-password", userId: s, secret: a } }) : h();
1375
1377
  break;
1376
1378
  case "verify-email":
1377
- s && a ? (await S(
1379
+ s && a ? (await A(
1378
1380
  this.acct(),
1379
1381
  ["updateEmailVerification", "updateVerification"],
1380
1382
  [s, a]
@@ -1384,26 +1386,26 @@ class Ft {
1384
1386
  message: this.getStrings().emailVerified,
1385
1387
  tone: "success"
1386
1388
  }
1387
- })) : c();
1389
+ })) : h();
1388
1390
  break;
1389
1391
  }
1390
- } catch (u) {
1391
- const b = _(u), $ = K(u, this.getStrings(), "link");
1392
- this.emit("error", b), this.setState({ pending: { type: "notice", message: $, tone: "error" } });
1392
+ } catch (d) {
1393
+ const g = q(d), y = Y(d, this.getStrings(), "link");
1394
+ this.emit("error", g), this.setState({ pending: { type: "notice", message: y, tone: "error" } });
1393
1395
  }
1394
1396
  return !0;
1395
1397
  }
1396
1398
  cleanUrl() {
1397
1399
  const t = new URL(window.location.href);
1398
- for (const i of mt) t.searchParams.delete(i);
1400
+ for (const i of ft) t.searchParams.delete(i);
1399
1401
  window.history.replaceState(window.history.state, "", t.toString());
1400
1402
  }
1401
1403
  /** Test helper. */
1402
1404
  reset() {
1403
- this.client = null, this.account = null, this.teams = null, this.activeTeamId = null, this.preview = null, this.config = null, this.state = ft(), this.listeners.clear();
1405
+ this.client = null, this.account = null, this.teams = null, this.activeTeamId = null, this.preview = null, this.config = null, this.state = gt(), this.listeners.clear();
1404
1406
  }
1405
1407
  }
1406
- const o = new Ft();
1408
+ const o = new Lt();
1407
1409
  class Rt {
1408
1410
  constructor() {
1409
1411
  this.listeners = /* @__PURE__ */ new Set(), this.observer = null, this.media = null, this.notify = () => {
@@ -1432,14 +1434,14 @@ class Rt {
1432
1434
  this.observer?.disconnect(), this.observer = null, this.media?.removeEventListener?.("change", this.notify), this.media = null;
1433
1435
  }
1434
1436
  }
1435
- const gt = new Rt(), vt = {
1437
+ const vt = new Rt(), bt = {
1436
1438
  none: "0px",
1437
1439
  sm: "0.25rem",
1438
1440
  md: "0.625rem",
1439
1441
  lg: "0.875rem",
1440
1442
  xl: "1.125rem",
1441
1443
  full: "1.5rem"
1442
- }, Tt = O`
1444
+ }, Tt = L`
1443
1445
  :host {
1444
1446
  /* Light theme (matches :root in the console) */
1445
1447
  --authui-background: oklch(1 0 0);
@@ -1517,7 +1519,7 @@ const gt = new Rt(), vt = {
1517
1519
  --authui-shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.5), 0 4px 6px -4px rgba(0, 0, 0, 0.5);
1518
1520
  color-scheme: dark;
1519
1521
  }
1520
- `, Dt = O`
1522
+ `, Dt = L`
1521
1523
  *,
1522
1524
  *::before,
1523
1525
  *::after {
@@ -2209,6 +2211,34 @@ const gt = new Rt(), vt = {
2209
2211
  .legal a:hover {
2210
2212
  color: var(--authui-foreground);
2211
2213
  }
2214
+ .legal-accept {
2215
+ display: flex;
2216
+ align-items: flex-start;
2217
+ gap: 10px;
2218
+ font-size: 12px;
2219
+ color: var(--authui-muted-foreground);
2220
+ line-height: 1.5;
2221
+ text-align: start;
2222
+ cursor: pointer;
2223
+ user-select: none;
2224
+ }
2225
+ .legal-accept input {
2226
+ margin-top: 2px;
2227
+ width: 16px;
2228
+ height: 16px;
2229
+ flex-shrink: 0;
2230
+ accent-color: var(--authui-brand);
2231
+ cursor: pointer;
2232
+ }
2233
+ .legal-accept a {
2234
+ color: inherit;
2235
+ text-decoration: underline;
2236
+ text-decoration-style: dotted;
2237
+ text-underline-offset: 3px;
2238
+ }
2239
+ .legal-accept a:hover {
2240
+ color: var(--authui-foreground);
2241
+ }
2212
2242
  .links {
2213
2243
  display: flex;
2214
2244
  justify-content: center;
@@ -2232,6 +2262,32 @@ const gt = new Rt(), vt = {
2232
2262
  width: 18px;
2233
2263
  height: 18px;
2234
2264
  }
2265
+ /* Compact icon-only OAuth row (oauthLayout: icon / horizontal). */
2266
+ .providers.icon {
2267
+ display: flex;
2268
+ flex-wrap: wrap;
2269
+ gap: 8px;
2270
+ justify-content: center;
2271
+ }
2272
+ .providers.icon .btn {
2273
+ width: 40px;
2274
+ height: 40px;
2275
+ padding: 0;
2276
+ justify-content: center;
2277
+ position: relative;
2278
+ }
2279
+ .providers.icon .btn svg {
2280
+ width: 18px;
2281
+ height: 18px;
2282
+ }
2283
+ .providers.icon .last-used-badge,
2284
+ .providers.icon .oauth-last-used-pill {
2285
+ display: none;
2286
+ }
2287
+ .providers.icon .oauth-last-used-dot {
2288
+ top: 4px;
2289
+ inset-inline-end: 4px;
2290
+ }
2235
2291
  /* OAuth accordion: last-used (or focused) expands; others stay icon-compact. */
2236
2292
  .providers.accordion {
2237
2293
  display: flex;
@@ -2467,24 +2523,24 @@ const gt = new Rt(), vt = {
2467
2523
  }
2468
2524
  `;
2469
2525
  var zt = Object.defineProperty, _t = (e, t, i, s) => {
2470
- for (var a = void 0, c = e.length - 1, u; c >= 0; c--)
2471
- (u = e[c]) && (a = u(t, i, a) || a);
2526
+ for (var a = void 0, h = e.length - 1, d; h >= 0; h--)
2527
+ (d = e[h]) && (a = d(t, i, a) || a);
2472
2528
  return a && zt(t, i, a), a;
2473
- }, M;
2474
- const $t = (M = class extends rt {
2529
+ }, O;
2530
+ const xt = (O = class extends nt {
2475
2531
  constructor() {
2476
2532
  super(...arguments), this.auth = o.getState(), this.unsubscribeStore = null, this.unsubscribeTheme = null, this.stopKeys = (t) => t.stopPropagation();
2477
2533
  }
2478
2534
  connectedCallback() {
2479
2535
  super.connectedCallback();
2480
- for (const t of M.KEY_EVENTS) this.addEventListener(t, this.stopKeys);
2536
+ for (const t of O.KEY_EVENTS) this.addEventListener(t, this.stopKeys);
2481
2537
  this.auth = o.getState(), this.unsubscribeStore = o.on("change", (t) => {
2482
2538
  this.auth = t, this.applyBranding();
2483
- }), this.unsubscribeTheme = gt.subscribe(() => this.applyBranding()), this.applyBranding();
2539
+ }), this.unsubscribeTheme = vt.subscribe(() => this.applyBranding()), this.applyBranding();
2484
2540
  }
2485
2541
  disconnectedCallback() {
2486
2542
  super.disconnectedCallback();
2487
- for (const t of M.KEY_EVENTS) this.removeEventListener(t, this.stopKeys);
2543
+ for (const t of O.KEY_EVENTS) this.removeEventListener(t, this.stopKeys);
2488
2544
  this.unsubscribeStore?.(), this.unsubscribeTheme?.(), this.unsubscribeStore = null, this.unsubscribeTheme = null;
2489
2545
  }
2490
2546
  get strings() {
@@ -2492,7 +2548,7 @@ const $t = (M = class extends rt {
2492
2548
  }
2493
2549
  /** Translate a string key with optional `{placeholders}`. */
2494
2550
  t(t, i) {
2495
- return St(this.strings[t], i);
2551
+ return At(this.strings[t], i);
2496
2552
  }
2497
2553
  get config() {
2498
2554
  return o.getConfig();
@@ -2502,29 +2558,29 @@ const $t = (M = class extends rt {
2502
2558
  }
2503
2559
  /** Push theme and branding from config onto the host element. */
2504
2560
  applyBranding() {
2505
- const t = this.config?.branding, i = gt.isDark(t?.theme ?? "auto");
2561
+ const t = this.config?.branding, i = vt.isDark(t?.theme ?? "auto");
2506
2562
  this.setAttribute("data-theme", i ? "dark" : "light"), t?.primary && (this.style.setProperty("--authui-primary", t.primary), this.style.setProperty(
2507
2563
  "--authui-primary-foreground",
2508
2564
  t.primaryForeground ?? "#ffffff"
2509
- )), t?.radius && vt[t.radius] && this.style.setProperty("--authui-radius", vt[t.radius]);
2565
+ )), t?.radius && bt[t.radius] && this.style.setProperty("--authui-radius", bt[t.radius]);
2510
2566
  }
2511
2567
  /** Emit a composed custom event from this element. */
2512
2568
  fire(t, i) {
2513
2569
  this.dispatchEvent(new CustomEvent(t, { detail: i, bubbles: !0, composed: !0 }));
2514
2570
  }
2515
- }, M.styles = [Tt, Dt], M.KEY_EVENTS = ["keydown", "keyup", "keypress"], M);
2571
+ }, O.styles = [Tt, Dt], O.KEY_EVENTS = ["keydown", "keyup", "keypress"], O);
2516
2572
  _t([
2517
- d()
2518
- ], $t.prototype, "auth");
2519
- let E = $t;
2520
- var Lt = Object.defineProperty, Vt = Object.getOwnPropertyDescriptor, w = (e, t, i, s) => {
2521
- for (var a = s > 1 ? void 0 : s ? Vt(t, i) : t, c = e.length - 1, u; c >= 0; c--)
2522
- (u = e[c]) && (a = (s ? u(t, i, a) : u(a)) || a);
2523
- return s && a && Lt(t, i, a), a;
2573
+ c()
2574
+ ], xt.prototype, "auth");
2575
+ let U = xt;
2576
+ var qt = Object.defineProperty, Vt = Object.getOwnPropertyDescriptor, x = (e, t, i, s) => {
2577
+ for (var a = s > 1 ? void 0 : s ? Vt(t, i) : t, h = e.length - 1, d; h >= 0; h--)
2578
+ (d = e[h]) && (a = (s ? d(t, i, a) : d(a)) || a);
2579
+ return s && a && qt(t, i, a), a;
2524
2580
  };
2525
- let y = class extends rt {
2581
+ let w = class extends nt {
2526
2582
  constructor() {
2527
- super(...arguments), this.endpoint = "", this.project = "", this.redirectUrl = "", this.successUrl = "", this.methods = "email-password", this.signUp = "true", this.requireName = "true", this.mfa = "true", this.securityPhrase = "true", this.name = "", this.logo = "", this.theme = "auto", this.radius = "", this.primary = "", this.primaryForeground = "", this.termsUrl = "", this.privacyUrl = "", this.preview = "";
2583
+ super(...arguments), this.endpoint = "", this.project = "", this.redirectUrl = "", this.successUrl = "", this.methods = "email-password", this.signUp = "true", this.requireName = "true", this.mfa = "true", this.securityPhrase = "true", this.name = "", this.logo = "", this.theme = "auto", this.radius = "", this.primary = "", this.primaryForeground = "", this.termsUrl = "", this.privacyUrl = "", this.requireAcceptance = "", this.oauthLayout = "", this.preview = "";
2528
2584
  }
2529
2585
  connectedCallback() {
2530
2586
  super.connectedCallback(), this.configure();
@@ -2546,7 +2602,7 @@ let y = class extends rt {
2546
2602
  const e = { oauth: [] }, t = this.methods.split(/[\s,]+/).filter(Boolean);
2547
2603
  for (const i of t)
2548
2604
  i.startsWith("oauth:") ? e.oauth.push(i.slice(6)) : i === "email-password" ? e.emailPassword = !0 : i === "magic-url" ? e.magicUrl = !0 : i === "email-otp" ? e.emailOtp = !0 : i === "phone" ? e.phone = !0 : (i === "anonymous" || i === "guest") && (e.anonymous = !0);
2549
- return e.emailPassword = t.length > 0 ? t.includes("email-password") : !0, {
2605
+ return e.emailPassword = t.length > 0 ? t.includes("email-password") : !0, this.oauthLayout && (e.oauthLayout = this.oauthLayout), {
2550
2606
  endpoint: this.endpoint,
2551
2607
  project: this.project,
2552
2608
  redirectUrl: this.redirectUrl || void 0,
@@ -2566,108 +2622,115 @@ let y = class extends rt {
2566
2622
  },
2567
2623
  legal: {
2568
2624
  termsUrl: this.termsUrl || void 0,
2569
- privacyUrl: this.privacyUrl || void 0
2625
+ privacyUrl: this.privacyUrl || void 0,
2626
+ requireAcceptance: this.requireAcceptance !== "" && this.requireAcceptance !== "false" ? !0 : void 0
2570
2627
  },
2571
2628
  preview: this.preview === "" || this.preview === "false" ? void 0 : !0
2572
2629
  };
2573
2630
  }
2574
2631
  };
2575
- y.styles = O`
2632
+ w.styles = L`
2576
2633
  :host {
2577
2634
  display: none;
2578
2635
  }
2579
2636
  `;
2580
- w([
2581
- g({ type: String })
2582
- ], y.prototype, "endpoint", 2);
2583
- w([
2584
- g({ type: String })
2585
- ], y.prototype, "project", 2);
2586
- w([
2587
- g({ type: String, attribute: "redirect-url" })
2588
- ], y.prototype, "redirectUrl", 2);
2589
- w([
2590
- g({ type: String, attribute: "success-url" })
2591
- ], y.prototype, "successUrl", 2);
2592
- w([
2593
- g({ type: String })
2594
- ], y.prototype, "methods", 2);
2595
- w([
2596
- g({ type: String, attribute: "sign-up" })
2597
- ], y.prototype, "signUp", 2);
2598
- w([
2599
- g({ type: String, attribute: "require-name" })
2600
- ], y.prototype, "requireName", 2);
2601
- w([
2602
- g({ type: String })
2603
- ], y.prototype, "mfa", 2);
2604
- w([
2605
- g({ type: String, attribute: "security-phrase" })
2606
- ], y.prototype, "securityPhrase", 2);
2607
- w([
2608
- g({ type: String })
2609
- ], y.prototype, "name", 2);
2610
- w([
2611
- g({ type: String })
2612
- ], y.prototype, "logo", 2);
2613
- w([
2614
- g({ type: String })
2615
- ], y.prototype, "theme", 2);
2616
- w([
2617
- g({ type: String })
2618
- ], y.prototype, "radius", 2);
2619
- w([
2620
- g({ type: String })
2621
- ], y.prototype, "primary", 2);
2622
- w([
2623
- g({ type: String, attribute: "primary-foreground" })
2624
- ], y.prototype, "primaryForeground", 2);
2625
- w([
2626
- g({ type: String, attribute: "terms-url" })
2627
- ], y.prototype, "termsUrl", 2);
2628
- w([
2629
- g({ type: String, attribute: "privacy-url" })
2630
- ], y.prototype, "privacyUrl", 2);
2631
- w([
2632
- g({ type: String })
2633
- ], y.prototype, "preview", 2);
2634
- y = w([
2637
+ x([
2638
+ m({ type: String })
2639
+ ], w.prototype, "endpoint", 2);
2640
+ x([
2641
+ m({ type: String })
2642
+ ], w.prototype, "project", 2);
2643
+ x([
2644
+ m({ type: String, attribute: "redirect-url" })
2645
+ ], w.prototype, "redirectUrl", 2);
2646
+ x([
2647
+ m({ type: String, attribute: "success-url" })
2648
+ ], w.prototype, "successUrl", 2);
2649
+ x([
2650
+ m({ type: String })
2651
+ ], w.prototype, "methods", 2);
2652
+ x([
2653
+ m({ type: String, attribute: "sign-up" })
2654
+ ], w.prototype, "signUp", 2);
2655
+ x([
2656
+ m({ type: String, attribute: "require-name" })
2657
+ ], w.prototype, "requireName", 2);
2658
+ x([
2659
+ m({ type: String })
2660
+ ], w.prototype, "mfa", 2);
2661
+ x([
2662
+ m({ type: String, attribute: "security-phrase" })
2663
+ ], w.prototype, "securityPhrase", 2);
2664
+ x([
2665
+ m({ type: String })
2666
+ ], w.prototype, "name", 2);
2667
+ x([
2668
+ m({ type: String })
2669
+ ], w.prototype, "logo", 2);
2670
+ x([
2671
+ m({ type: String })
2672
+ ], w.prototype, "theme", 2);
2673
+ x([
2674
+ m({ type: String })
2675
+ ], w.prototype, "radius", 2);
2676
+ x([
2677
+ m({ type: String })
2678
+ ], w.prototype, "primary", 2);
2679
+ x([
2680
+ m({ type: String, attribute: "primary-foreground" })
2681
+ ], w.prototype, "primaryForeground", 2);
2682
+ x([
2683
+ m({ type: String, attribute: "terms-url" })
2684
+ ], w.prototype, "termsUrl", 2);
2685
+ x([
2686
+ m({ type: String, attribute: "privacy-url" })
2687
+ ], w.prototype, "privacyUrl", 2);
2688
+ x([
2689
+ m({ type: String, attribute: "require-acceptance" })
2690
+ ], w.prototype, "requireAcceptance", 2);
2691
+ x([
2692
+ m({ type: String, attribute: "oauth-layout" })
2693
+ ], w.prototype, "oauthLayout", 2);
2694
+ x([
2695
+ m({ type: String })
2696
+ ], w.prototype, "preview", 2);
2697
+ w = x([
2635
2698
  T("authui-config")
2636
- ], y);
2637
- var qt = Object.defineProperty, Nt = Object.getOwnPropertyDescriptor, X = (e, t, i, s) => {
2638
- for (var a = s > 1 ? void 0 : s ? Nt(t, i) : t, c = e.length - 1, u; c >= 0; c--)
2639
- (u = e[c]) && (a = (s ? u(t, i, a) : u(a)) || a);
2640
- return s && a && qt(t, i, a), a;
2699
+ ], w);
2700
+ var Nt = Object.defineProperty, Bt = Object.getOwnPropertyDescriptor, Q = (e, t, i, s) => {
2701
+ for (var a = s > 1 ? void 0 : s ? Bt(t, i) : t, h = e.length - 1, d; h >= 0; h--)
2702
+ (d = e[h]) && (a = (s ? d(t, i, a) : d(a)) || a);
2703
+ return s && a && Nt(t, i, a), a;
2641
2704
  };
2642
- const bt = "authui-show:not([ready]){display:none}", le = "authui-show:not([ready]){display:none}authui-button:not(:defined),authui-user-button:not(:defined){visibility:hidden}";
2643
- let yt = !1;
2644
- function Bt() {
2645
- if (!(typeof document > "u" || yt)) {
2646
- yt = !0;
2705
+ const yt = "authui-show:not([ready]){display:none}", ce = "authui-show:not([ready]){display:none}authui-button:not(:defined),authui-user-button:not(:defined){visibility:hidden}";
2706
+ let wt = !1;
2707
+ function jt() {
2708
+ if (!(typeof document > "u" || wt)) {
2709
+ wt = !0;
2647
2710
  try {
2648
2711
  if (typeof CSSStyleSheet < "u" && "adoptedStyleSheets" in Document.prototype) {
2649
2712
  const e = new CSSStyleSheet();
2650
- e.replaceSync(bt), document.adoptedStyleSheets = [...document.adoptedStyleSheets, e];
2713
+ e.replaceSync(yt), document.adoptedStyleSheets = [...document.adoptedStyleSheets, e];
2651
2714
  return;
2652
2715
  }
2653
2716
  } catch {
2654
2717
  }
2655
2718
  if (!document.getElementById("authui-fouc")) {
2656
2719
  const e = document.createElement("style");
2657
- e.id = "authui-fouc", e.textContent = bt, document.head.appendChild(e);
2720
+ e.id = "authui-fouc", e.textContent = yt, document.head.appendChild(e);
2658
2721
  }
2659
2722
  }
2660
2723
  }
2661
- Bt();
2724
+ jt();
2662
2725
  const Ht = ["loading", "signed-out", "signed-in", "mfa-required"];
2663
- function et(e) {
2726
+ function st(e) {
2664
2727
  return e ? e.split(/[\s,]+/).map((t) => t.trim()).filter((t) => Ht.includes(t)) : [];
2665
2728
  }
2666
- function jt(e, t, i) {
2667
- const s = et(t), a = et(i);
2729
+ function Wt(e, t, i) {
2730
+ const s = st(t), a = st(i);
2668
2731
  return !(e === "loading" && !s.includes("loading") || s.length > 0 && !s.includes(e) || a.includes(e));
2669
2732
  }
2670
- let N = class extends rt {
2733
+ let H = class extends nt {
2671
2734
  constructor() {
2672
2735
  super(...arguments), this.when = "", this.unless = "", this.status = o.getState().status, this.unsubscribe = null;
2673
2736
  }
@@ -2679,28 +2742,28 @@ let N = class extends rt {
2679
2742
  }
2680
2743
  /** Whether the current status satisfies `when` and `unless`. */
2681
2744
  get visible() {
2682
- return jt(this.status, this.when, this.unless);
2745
+ return Wt(this.status, this.when, this.unless);
2683
2746
  }
2684
2747
  updated() {
2685
- (this.status !== "loading" || et(this.when).includes("loading")) && (this.setAttribute("ready", ""), this.style.display = "contents");
2748
+ (this.status !== "loading" || st(this.when).includes("loading")) && (this.setAttribute("ready", ""), this.style.display = "contents");
2686
2749
  }
2687
2750
  render() {
2688
2751
  return this.visible ? r`<slot></slot>` : n;
2689
2752
  }
2690
2753
  };
2691
- X([
2692
- g({ type: String })
2693
- ], N.prototype, "when", 2);
2694
- X([
2695
- g({ type: String })
2696
- ], N.prototype, "unless", 2);
2697
- X([
2698
- d()
2699
- ], N.prototype, "status", 2);
2700
- N = X([
2754
+ Q([
2755
+ m({ type: String })
2756
+ ], H.prototype, "when", 2);
2757
+ Q([
2758
+ m({ type: String })
2759
+ ], H.prototype, "unless", 2);
2760
+ Q([
2761
+ c()
2762
+ ], H.prototype, "status", 2);
2763
+ H = Q([
2701
2764
  T("authui-show")
2702
- ], N);
2703
- const Wt = O`
2765
+ ], H);
2766
+ const Kt = L`
2704
2767
  :host {
2705
2768
  display: block;
2706
2769
  width: 100%;
@@ -2754,7 +2817,7 @@ const Wt = O`
2754
2817
  height: 14px;
2755
2818
  margin: 0;
2756
2819
  }
2757
- `, v = (e) => r`<svg
2820
+ `, b = (e) => r`<svg
2758
2821
  xmlns="http://www.w3.org/2000/svg"
2759
2822
  viewBox="0 0 24 24"
2760
2823
  fill="none"
@@ -2766,159 +2829,159 @@ const Wt = O`
2766
2829
  >
2767
2830
  ${e}
2768
2831
  </svg>`, l = {
2769
- mail: v(
2770
- h`<rect width="20" height="16" x="2" y="4" rx="2"/><path d="m22 7-8.97 5.7a1.94 1.94 0 0 1-2.06 0L2 7"/>`
2832
+ mail: b(
2833
+ u`<rect width="20" height="16" x="2" y="4" rx="2"/><path d="m22 7-8.97 5.7a1.94 1.94 0 0 1-2.06 0L2 7"/>`
2771
2834
  ),
2772
- phone: v(
2773
- h`<path d="M22 16.92v3a2 2 0 0 1-2.18 2 19.79 19.79 0 0 1-8.63-3.07 19.5 19.5 0 0 1-6-6 19.79 19.79 0 0 1-3.07-8.67A2 2 0 0 1 4.11 2h3a2 2 0 0 1 2 1.72 12.84 12.84 0 0 0 .7 2.81 2 2 0 0 1-.45 2.11L8.09 9.91a16 16 0 0 0 6 6l1.27-1.27a2 2 0 0 1 2.11-.45 12.84 12.84 0 0 0 2.81.7A2 2 0 0 1 22 16.92z"/>`
2835
+ phone: b(
2836
+ u`<path d="M22 16.92v3a2 2 0 0 1-2.18 2 19.79 19.79 0 0 1-8.63-3.07 19.5 19.5 0 0 1-6-6 19.79 19.79 0 0 1-3.07-8.67A2 2 0 0 1 4.11 2h3a2 2 0 0 1 2 1.72 12.84 12.84 0 0 0 .7 2.81 2 2 0 0 1-.45 2.11L8.09 9.91a16 16 0 0 0 6 6l1.27-1.27a2 2 0 0 1 2.11-.45 12.84 12.84 0 0 0 2.81.7A2 2 0 0 1 22 16.92z"/>`
2774
2837
  ),
2775
- user: v(
2776
- h`<path d="M19 21v-2a4 4 0 0 0-4-4H9a4 4 0 0 0-4 4v2"/><circle cx="12" cy="7" r="4"/>`
2838
+ user: b(
2839
+ u`<path d="M19 21v-2a4 4 0 0 0-4-4H9a4 4 0 0 0-4 4v2"/><circle cx="12" cy="7" r="4"/>`
2777
2840
  ),
2778
- userX: v(
2779
- h`<path d="M2 21a8 8 0 0 1 11.873-7"/><circle cx="10" cy="8" r="5"/><path d="m17 17 5 5"/><path d="m22 17-5 5"/>`
2841
+ userX: b(
2842
+ u`<path d="M2 21a8 8 0 0 1 11.873-7"/><circle cx="10" cy="8" r="5"/><path d="m17 17 5 5"/><path d="m22 17-5 5"/>`
2780
2843
  ),
2781
- lock: v(
2782
- h`<rect width="18" height="11" x="3" y="11" rx="2" ry="2"/><path d="M7 11V7a5 5 0 0 1 10 0v4"/>`
2844
+ lock: b(
2845
+ u`<rect width="18" height="11" x="3" y="11" rx="2" ry="2"/><path d="M7 11V7a5 5 0 0 1 10 0v4"/>`
2783
2846
  ),
2784
- key: v(
2785
- h`<path d="m15.5 7.5 2.3 2.3a1 1 0 0 0 1.4 0l2.1-2.1a1 1 0 0 0 0-1.4L19 4"/><path d="m21 2-9.6 9.6"/><circle cx="7.5" cy="15.5" r="5.5"/>`
2847
+ key: b(
2848
+ u`<path d="m15.5 7.5 2.3 2.3a1 1 0 0 0 1.4 0l2.1-2.1a1 1 0 0 0 0-1.4L19 4"/><path d="m21 2-9.6 9.6"/><circle cx="7.5" cy="15.5" r="5.5"/>`
2786
2849
  ),
2787
- shield: v(
2788
- h`<path d="M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z"/>`
2850
+ shield: b(
2851
+ u`<path d="M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z"/>`
2789
2852
  ),
2790
- shieldCheck: v(
2791
- h`<path d="M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z"/><path d="m9 12 2 2 4-4"/>`
2853
+ shieldCheck: b(
2854
+ u`<path d="M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z"/><path d="m9 12 2 2 4-4"/>`
2792
2855
  ),
2793
- smartphone: v(
2794
- h`<rect width="14" height="20" x="5" y="2" rx="2" ry="2"/><path d="M12 18h.01"/>`
2856
+ smartphone: b(
2857
+ u`<rect width="14" height="20" x="5" y="2" rx="2" ry="2"/><path d="M12 18h.01"/>`
2795
2858
  ),
2796
- monitor: v(
2797
- h`<rect width="20" height="14" x="2" y="3" rx="2"/><line x1="8" x2="16" y1="21" y2="21"/><line x1="12" x2="12" y1="17" y2="21"/>`
2859
+ monitor: b(
2860
+ u`<rect width="20" height="14" x="2" y="3" rx="2"/><line x1="8" x2="16" y1="21" y2="21"/><line x1="12" x2="12" y1="17" y2="21"/>`
2798
2861
  ),
2799
- globe: v(
2800
- h`<circle cx="12" cy="12" r="10"/><path d="M12 2a14.5 14.5 0 0 0 0 20 14.5 14.5 0 0 0 0-20"/><path d="M2 12h20"/>`
2862
+ globe: b(
2863
+ u`<circle cx="12" cy="12" r="10"/><path d="M12 2a14.5 14.5 0 0 0 0 20 14.5 14.5 0 0 0 0-20"/><path d="M2 12h20"/>`
2801
2864
  ),
2802
- logOut: v(
2803
- h`<path d="M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4"/><polyline points="16 17 21 12 16 7"/><line x1="21" x2="9" y1="12" y2="12"/>`
2865
+ logOut: b(
2866
+ u`<path d="M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4"/><polyline points="16 17 21 12 16 7"/><line x1="21" x2="9" y1="12" y2="12"/>`
2804
2867
  ),
2805
- settings: v(
2806
- h`<path d="M12.22 2h-.44a2 2 0 0 0-2 2v.18a2 2 0 0 1-1 1.73l-.43.25a2 2 0 0 1-2 0l-.15-.08a2 2 0 0 0-2.73.73l-.22.38a2 2 0 0 0 .73 2.73l.15.1a2 2 0 0 1 1 1.72v.51a2 2 0 0 1-1 1.74l-.15.09a2 2 0 0 0-.73 2.73l.22.38a2 2 0 0 0 2.73.73l.15-.08a2 2 0 0 1 2 0l.43.25a2 2 0 0 1 1 1.73V20a2 2 0 0 0 2 2h.44a2 2 0 0 0 2-2v-.18a2 2 0 0 1 1-1.73l.43-.25a2 2 0 0 1 2 0l.15.08a2 2 0 0 0 2.73-.73l.22-.39a2 2 0 0 0-.73-2.73l-.15-.08a2 2 0 0 1-1-1.74v-.5a2 2 0 0 1 1-1.74l.15-.09a2 2 0 0 0 .73-2.73l-.22-.38a2 2 0 0 0-2.73-.73l-.15.08a2 2 0 0 1-2 0l-.43-.25a2 2 0 0 1-1-1.73V4a2 2 0 0 0-2-2z"/><circle cx="12" cy="12" r="3"/>`
2868
+ settings: b(
2869
+ u`<path d="M12.22 2h-.44a2 2 0 0 0-2 2v.18a2 2 0 0 1-1 1.73l-.43.25a2 2 0 0 1-2 0l-.15-.08a2 2 0 0 0-2.73.73l-.22.38a2 2 0 0 0 .73 2.73l.15.1a2 2 0 0 1 1 1.72v.51a2 2 0 0 1-1 1.74l-.15.09a2 2 0 0 0-.73 2.73l.22.38a2 2 0 0 0 2.73.73l.15-.08a2 2 0 0 1 2 0l.43.25a2 2 0 0 1 1 1.73V20a2 2 0 0 0 2 2h.44a2 2 0 0 0 2-2v-.18a2 2 0 0 1 1-1.73l.43-.25a2 2 0 0 1 2 0l.15.08a2 2 0 0 0 2.73-.73l.22-.39a2 2 0 0 0-.73-2.73l-.15-.08a2 2 0 0 1-1-1.74v-.5a2 2 0 0 1 1-1.74l.15-.09a2 2 0 0 0 .73-2.73l-.22-.38a2 2 0 0 0-2.73-.73l-.15.08a2 2 0 0 1-2 0l-.43-.25a2 2 0 0 1-1-1.73V4a2 2 0 0 0-2-2z"/><circle cx="12" cy="12" r="3"/>`
2807
2870
  ),
2808
- x: v(h`<path d="M18 6 6 18"/><path d="m6 6 12 12"/>`),
2809
- check: v(h`<path d="M20 6 9 17l-5-5"/>`),
2810
- users: v(
2811
- h`<path d="M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2"/><circle cx="9" cy="7" r="4"/><path d="M22 21v-2a4 4 0 0 0-3-3.87"/><path d="M16 3.13a4 4 0 0 1 0 7.75"/>`
2871
+ x: b(u`<path d="M18 6 6 18"/><path d="m6 6 12 12"/>`),
2872
+ check: b(u`<path d="M20 6 9 17l-5-5"/>`),
2873
+ users: b(
2874
+ u`<path d="M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2"/><circle cx="9" cy="7" r="4"/><path d="M22 21v-2a4 4 0 0 0-3-3.87"/><path d="M16 3.13a4 4 0 0 1 0 7.75"/>`
2812
2875
  ),
2813
- copy: v(
2814
- h`<rect width="14" height="14" x="8" y="8" rx="2" ry="2"/><path d="M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2"/>`
2876
+ copy: b(
2877
+ u`<rect width="14" height="14" x="8" y="8" rx="2" ry="2"/><path d="M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2"/>`
2815
2878
  ),
2816
- eye: v(
2817
- h`<path d="M2.062 12.348a1 1 0 0 1 0-.696 10.75 10.75 0 0 1 19.876 0 1 1 0 0 1 0 .696 10.75 10.75 0 0 1-19.876 0"/><circle cx="12" cy="12" r="3"/>`
2879
+ eye: b(
2880
+ u`<path d="M2.062 12.348a1 1 0 0 1 0-.696 10.75 10.75 0 0 1 19.876 0 1 1 0 0 1 0 .696 10.75 10.75 0 0 1-19.876 0"/><circle cx="12" cy="12" r="3"/>`
2818
2881
  ),
2819
- eyeOff: v(
2820
- h`<path d="M10.733 5.076a10.744 10.744 0 0 1 11.205 6.575 1 1 0 0 1 0 .696 10.747 10.747 0 0 1-1.444 2.49"/><path d="M14.084 14.158a3 3 0 0 1-4.242-4.242"/><path d="M17.479 17.499a10.75 10.75 0 0 1-15.417-5.151 1 1 0 0 1 0-.696 10.75 10.75 0 0 1 4.446-5.143"/><path d="m2 2 20 20"/>`
2882
+ eyeOff: b(
2883
+ u`<path d="M10.733 5.076a10.744 10.744 0 0 1 11.205 6.575 1 1 0 0 1 0 .696 10.747 10.747 0 0 1-1.444 2.49"/><path d="M14.084 14.158a3 3 0 0 1-4.242-4.242"/><path d="M17.479 17.499a10.75 10.75 0 0 1-15.417-5.151 1 1 0 0 1 0-.696 10.75 10.75 0 0 1 4.446-5.143"/><path d="m2 2 20 20"/>`
2821
2884
  ),
2822
- arrowLeft: v(h`<path d="m12 19-7-7 7-7"/><path d="M19 12H5"/>`),
2823
- alert: v(
2824
- h`<circle cx="12" cy="12" r="10"/><line x1="12" x2="12" y1="8" y2="12"/><line x1="12" x2="12.01" y1="16" y2="16"/>`
2885
+ arrowLeft: b(u`<path d="m12 19-7-7 7-7"/><path d="M19 12H5"/>`),
2886
+ alert: b(
2887
+ u`<circle cx="12" cy="12" r="10"/><line x1="12" x2="12" y1="8" y2="12"/><line x1="12" x2="12.01" y1="16" y2="16"/>`
2825
2888
  ),
2826
- info: v(h`<circle cx="12" cy="12" r="10"/><path d="M12 16v-4"/><path d="M12 8h.01"/>`),
2827
- checkCircle: v(h`<circle cx="12" cy="12" r="10"/><path d="m9 12 2 2 4-4"/>`),
2828
- link: v(
2829
- h`<path d="M10 13a5 5 0 0 0 7.54.54l3-3a5 5 0 0 0-7.07-7.07l-1.72 1.71"/><path d="M14 11a5 5 0 0 0-7.54-.54l-3 3a5 5 0 0 0 7.07 7.07l1.71-1.71"/>`
2889
+ info: b(u`<circle cx="12" cy="12" r="10"/><path d="M12 16v-4"/><path d="M12 8h.01"/>`),
2890
+ checkCircle: b(u`<circle cx="12" cy="12" r="10"/><path d="m9 12 2 2 4-4"/>`),
2891
+ link: b(
2892
+ u`<path d="M10 13a5 5 0 0 0 7.54.54l3-3a5 5 0 0 0-7.07-7.07l-1.72 1.71"/><path d="M14 11a5 5 0 0 0-7.54-.54l-3 3a5 5 0 0 0 7.07 7.07l1.71-1.71"/>`
2830
2893
  ),
2831
- activity: v(
2832
- h`<path d="M22 12h-2.48a2 2 0 0 0-1.93 1.46l-2.35 8.36a.25.25 0 0 1-.48 0L9.24 2.18a.25.25 0 0 0-.48 0l-2.35 8.36A2 2 0 0 1 4.49 12H2"/>`
2894
+ activity: b(
2895
+ u`<path d="M22 12h-2.48a2 2 0 0 0-1.93 1.46l-2.35 8.36a.25.25 0 0 1-.48 0L9.24 2.18a.25.25 0 0 0-.48 0l-2.35 8.36A2 2 0 0 1 4.49 12H2"/>`
2833
2896
  ),
2834
- trash: v(
2835
- h`<path d="M3 6h18"/><path d="M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6"/><path d="M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2"/>`
2897
+ trash: b(
2898
+ u`<path d="M3 6h18"/><path d="M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6"/><path d="M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2"/>`
2836
2899
  ),
2837
- sparkles: v(
2838
- h`<path d="M9.937 15.5A2 2 0 0 0 8.5 14.063l-6.135-1.582a.5.5 0 0 1 0-.962L8.5 9.936A2 2 0 0 0 9.937 8.5l1.582-6.135a.5.5 0 0 1 .963 0L14.063 8.5A2 2 0 0 0 15.5 9.937l6.135 1.581a.5.5 0 0 1 0 .964L15.5 14.063a2 2 0 0 0-1.437 1.437l-1.582 6.135a.5.5 0 0 1-.963 0z"/>`
2900
+ sparkles: b(
2901
+ u`<path d="M9.937 15.5A2 2 0 0 0 8.5 14.063l-6.135-1.582a.5.5 0 0 1 0-.962L8.5 9.936A2 2 0 0 0 9.937 8.5l1.582-6.135a.5.5 0 0 1 .963 0L14.063 8.5A2 2 0 0 0 15.5 9.937l6.135 1.581a.5.5 0 0 1 0 .964L15.5 14.063a2 2 0 0 0-1.437 1.437l-1.582 6.135a.5.5 0 0 1-.963 0z"/>`
2839
2902
  ),
2840
- refresh: v(
2841
- h`<path d="M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8"/><path d="M21 3v5h-5"/><path d="M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16"/><path d="M8 16H3v5"/>`
2903
+ refresh: b(
2904
+ u`<path d="M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8"/><path d="M21 3v5h-5"/><path d="M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16"/><path d="M8 16H3v5"/>`
2842
2905
  ),
2843
- chevronDown: v(h`<path d="m6 9 6 6 6-6"/>`),
2844
- ghost: v(
2845
- h`<path d="M9 10h.01"/><path d="M15 10h.01"/><path d="M12 2a8 8 0 0 0-8 8v12l3-3 2.5 2.5L12 19l2.5 2.5L17 19l3 3V10a8 8 0 0 0-8-8z"/>`
2906
+ chevronDown: b(u`<path d="m6 9 6 6 6-6"/>`),
2907
+ ghost: b(
2908
+ u`<path d="M9 10h.01"/><path d="M15 10h.01"/><path d="M12 2a8 8 0 0 0-8 8v12l3-3 2.5 2.5L12 19l2.5 2.5L17 19l3 3V10a8 8 0 0 0-8-8z"/>`
2846
2909
  ),
2847
- qr: v(
2848
- h`<rect width="5" height="5" x="3" y="3" rx="1"/><rect width="5" height="5" x="16" y="3" rx="1"/><rect width="5" height="5" x="3" y="16" rx="1"/><path d="M21 16h-3a2 2 0 0 0-2 2v3"/><path d="M21 21v.01"/><path d="M12 7v3a2 2 0 0 1-2 2H7"/><path d="M3 12h.01"/><path d="M12 3h.01"/><path d="M12 16v.01"/><path d="M16 12h1"/><path d="M21 12v.01"/><path d="M12 21v-1"/>`
2910
+ qr: b(
2911
+ u`<rect width="5" height="5" x="3" y="3" rx="1"/><rect width="5" height="5" x="16" y="3" rx="1"/><rect width="5" height="5" x="3" y="16" rx="1"/><path d="M21 16h-3a2 2 0 0 0-2 2v3"/><path d="M21 21v.01"/><path d="M12 7v3a2 2 0 0 1-2 2H7"/><path d="M3 12h.01"/><path d="M12 3h.01"/><path d="M12 16v.01"/><path d="M16 12h1"/><path d="M21 12v.01"/><path d="M12 21v-1"/>`
2849
2912
  )
2850
- }, x = (e, t = "0 0 24 24") => r`<svg xmlns="http://www.w3.org/2000/svg" viewBox=${t} aria-hidden="true">${e}</svg>`, Kt = {
2851
- google: x(
2852
- h`<path fill="#4285F4" d="M23.49 12.27c0-.79-.07-1.54-.19-2.27H12v4.51h6.47a5.57 5.57 0 0 1-2.4 3.58v3h3.86c2.26-2.09 3.56-5.17 3.56-8.82z"/><path fill="#34A853" d="M12 24c3.24 0 5.95-1.08 7.93-2.91l-3.86-3c-1.08.72-2.45 1.16-4.07 1.16-3.13 0-5.78-2.11-6.73-4.96H1.29v3.09A11.99 11.99 0 0 0 12 24z"/><path fill="#FBBC05" d="M5.27 14.29A7.2 7.2 0 0 1 4.89 12c0-.8.14-1.57.38-2.29V6.62H1.29A11.97 11.97 0 0 0 0 12c0 1.94.46 3.77 1.29 5.38l3.98-3.09z"/><path fill="#EA4335" d="M12 4.75c1.77 0 3.35.61 4.6 1.8l3.42-3.42C17.95 1.19 15.24 0 12 0 7.31 0 3.26 2.69 1.29 6.62l3.98 3.09C6.22 6.86 8.87 4.75 12 4.75z"/>`
2913
+ }, S = (e, t = "0 0 24 24") => r`<svg xmlns="http://www.w3.org/2000/svg" viewBox=${t} aria-hidden="true">${e}</svg>`, Gt = {
2914
+ google: S(
2915
+ u`<path fill="#4285F4" d="M23.49 12.27c0-.79-.07-1.54-.19-2.27H12v4.51h6.47a5.57 5.57 0 0 1-2.4 3.58v3h3.86c2.26-2.09 3.56-5.17 3.56-8.82z"/><path fill="#34A853" d="M12 24c3.24 0 5.95-1.08 7.93-2.91l-3.86-3c-1.08.72-2.45 1.16-4.07 1.16-3.13 0-5.78-2.11-6.73-4.96H1.29v3.09A11.99 11.99 0 0 0 12 24z"/><path fill="#FBBC05" d="M5.27 14.29A7.2 7.2 0 0 1 4.89 12c0-.8.14-1.57.38-2.29V6.62H1.29A11.97 11.97 0 0 0 0 12c0 1.94.46 3.77 1.29 5.38l3.98-3.09z"/><path fill="#EA4335" d="M12 4.75c1.77 0 3.35.61 4.6 1.8l3.42-3.42C17.95 1.19 15.24 0 12 0 7.31 0 3.26 2.69 1.29 6.62l3.98 3.09C6.22 6.86 8.87 4.75 12 4.75z"/>`
2853
2916
  ),
2854
- github: x(
2855
- h`<path fill="currentColor" d="M12 0C5.37 0 0 5.37 0 12c0 5.31 3.435 9.795 8.205 11.385.6.105.825-.255.825-.57 0-.285-.015-1.23-.015-2.235-3.015.555-3.795-.735-4.035-1.41-.135-.345-.72-1.41-1.23-1.695-.42-.225-1.02-.78-.015-.795.945-.015 1.62.87 1.845 1.23 1.08 1.815 2.805 1.305 3.495.99.105-.78.42-1.305.765-1.605-2.67-.3-5.46-1.335-5.46-5.925 0-1.305.465-2.385 1.23-3.225-.12-.3-.54-1.53.12-3.18 0 0 1.005-.315 3.3 1.23.96-.27 1.98-.405 3-.405s2.04.135 3 .405c2.295-1.56 3.3-1.23 3.3-1.23.66 1.65.24 2.88.12 3.18.765.84 1.23 1.905 1.23 3.225 0 4.605-2.805 5.625-5.475 5.925.435.375.81 1.095.81 2.22 0 1.605-.015 2.895-.015 3.3 0 .315.225.69.825.57A12.02 12.02 0 0 0 24 12c0-6.63-5.37-12-12-12z"/>`
2917
+ github: S(
2918
+ u`<path fill="currentColor" d="M12 0C5.37 0 0 5.37 0 12c0 5.31 3.435 9.795 8.205 11.385.6.105.825-.255.825-.57 0-.285-.015-1.23-.015-2.235-3.015.555-3.795-.735-4.035-1.41-.135-.345-.72-1.41-1.23-1.695-.42-.225-1.02-.78-.015-.795.945-.015 1.62.87 1.845 1.23 1.08 1.815 2.805 1.305 3.495.99.105-.78.42-1.305.765-1.605-2.67-.3-5.46-1.335-5.46-5.925 0-1.305.465-2.385 1.23-3.225-.12-.3-.54-1.53.12-3.18 0 0 1.005-.315 3.3 1.23.96-.27 1.98-.405 3-.405s2.04.135 3 .405c2.295-1.56 3.3-1.23 3.3-1.23.66 1.65.24 2.88.12 3.18.765.84 1.23 1.905 1.23 3.225 0 4.605-2.805 5.625-5.475 5.925.435.375.81 1.095.81 2.22 0 1.605-.015 2.895-.015 3.3 0 .315.225.69.825.57A12.02 12.02 0 0 0 24 12c0-6.63-5.37-12-12-12z"/>`
2856
2919
  ),
2857
- apple: x(
2858
- h`<path fill="currentColor" d="M17.05 20.28c-.98.95-2.05.8-3.08.35-1.09-.46-2.09-.48-3.24 0-1.44.62-2.2.44-3.06-.35C2.79 15.25 3.51 7.59 9.05 7.31c1.35.07 2.29.74 3.08.8 1.18-.24 2.31-.93 3.57-.84 1.51.12 2.65.72 3.4 1.8-3.12 1.87-2.38 5.98.48 7.13-.57 1.5-1.31 2.99-2.54 4.09zM12.03 7.25c-.15-2.23 1.66-4.07 3.74-4.25.29 2.58-2.34 4.5-3.74 4.25z"/>`
2920
+ apple: S(
2921
+ u`<path fill="currentColor" d="M17.05 20.28c-.98.95-2.05.8-3.08.35-1.09-.46-2.09-.48-3.24 0-1.44.62-2.2.44-3.06-.35C2.79 15.25 3.51 7.59 9.05 7.31c1.35.07 2.29.74 3.08.8 1.18-.24 2.31-.93 3.57-.84 1.51.12 2.65.72 3.4 1.8-3.12 1.87-2.38 5.98.48 7.13-.57 1.5-1.31 2.99-2.54 4.09zM12.03 7.25c-.15-2.23 1.66-4.07 3.74-4.25.29 2.58-2.34 4.5-3.74 4.25z"/>`
2859
2922
  ),
2860
- facebook: x(
2861
- h`<path fill="#1877F2" d="M24 12.073c0-6.627-5.373-12-12-12s-12 5.373-12 12c0 5.99 4.388 10.954 10.125 11.854v-8.385H7.078v-3.47h3.047V9.43c0-3.007 1.792-4.669 4.533-4.669 1.312 0 2.686.235 2.686.235v2.953H15.83c-1.491 0-1.956.925-1.956 1.874v2.25h3.328l-.532 3.47h-2.796v8.385C19.612 23.027 24 18.062 24 12.073z"/>`
2923
+ facebook: S(
2924
+ u`<path fill="#1877F2" d="M24 12.073c0-6.627-5.373-12-12-12s-12 5.373-12 12c0 5.99 4.388 10.954 10.125 11.854v-8.385H7.078v-3.47h3.047V9.43c0-3.007 1.792-4.669 4.533-4.669 1.312 0 2.686.235 2.686.235v2.953H15.83c-1.491 0-1.956.925-1.956 1.874v2.25h3.328l-.532 3.47h-2.796v8.385C19.612 23.027 24 18.062 24 12.073z"/>`
2862
2925
  ),
2863
- x: x(
2864
- h`<path fill="currentColor" d="M18.244 2.25h3.308l-7.227 8.26 8.502 11.24H16.17l-5.214-6.817L4.99 21.75H1.68l7.73-8.835L1.254 2.25H8.08l4.713 6.231zm-1.161 17.52h1.833L7.084 4.126H5.117z"/>`
2926
+ x: S(
2927
+ u`<path fill="currentColor" d="M18.244 2.25h3.308l-7.227 8.26 8.502 11.24H16.17l-5.214-6.817L4.99 21.75H1.68l7.73-8.835L1.254 2.25H8.08l4.713 6.231zm-1.161 17.52h1.833L7.084 4.126H5.117z"/>`
2865
2928
  ),
2866
- microsoft: x(
2867
- h`<path fill="#F25022" d="M1 1h10v10H1z"/><path fill="#7FBA00" d="M13 1h10v10H13z"/><path fill="#00A4EF" d="M1 13h10v10H1z"/><path fill="#FFB900" d="M13 13h10v10H13z"/>`
2929
+ microsoft: S(
2930
+ u`<path fill="#F25022" d="M1 1h10v10H1z"/><path fill="#7FBA00" d="M13 1h10v10H13z"/><path fill="#00A4EF" d="M1 13h10v10H1z"/><path fill="#FFB900" d="M13 13h10v10H13z"/>`
2868
2931
  ),
2869
- discord: x(
2870
- h`<path fill="#5865F2" d="M20.317 4.37a19.791 19.791 0 0 0-4.885-1.515.074.074 0 0 0-.079.037c-.21.375-.444.864-.608 1.25a18.27 18.27 0 0 0-5.487 0 12.64 12.64 0 0 0-.617-1.25.077.077 0 0 0-.079-.037A19.736 19.736 0 0 0 3.677 4.37a.07.07 0 0 0-.032.027C.533 9.046-.32 13.58.099 18.057a.082.082 0 0 0 .031.057 19.9 19.9 0 0 0 5.993 3.03.078.078 0 0 0 .084-.028c.462-.63.874-1.295 1.226-1.994a.076.076 0 0 0-.041-.106 13.107 13.107 0 0 1-1.872-.892.077.077 0 0 1-.008-.128 10.2 10.2 0 0 0 .372-.292.074.074 0 0 1 .077-.01c3.928 1.793 8.18 1.793 12.062 0a.074.074 0 0 1 .078.01c.12.098.246.198.373.292a.077.077 0 0 1-.006.127 12.299 12.299 0 0 1-1.873.892.077.077 0 0 0-.041.107c.36.698.772 1.362 1.225 1.993a.076.076 0 0 0 .084.028 19.839 19.839 0 0 0 6.002-3.03.077.077 0 0 0 .032-.054c.5-5.177-.838-9.674-3.549-13.66a.061.061 0 0 0-.031-.03zM8.02 15.33c-1.183 0-2.157-1.085-2.157-2.419 0-1.333.956-2.419 2.157-2.419 1.21 0 2.176 1.096 2.157 2.42 0 1.333-.956 2.418-2.157 2.418zm7.975 0c-1.183 0-2.157-1.085-2.157-2.419 0-1.333.955-2.419 2.157-2.419 1.21 0 2.176 1.096 2.157 2.42 0 1.333-.946 2.418-2.157 2.418z"/>`
2932
+ discord: S(
2933
+ u`<path fill="#5865F2" d="M20.317 4.37a19.791 19.791 0 0 0-4.885-1.515.074.074 0 0 0-.079.037c-.21.375-.444.864-.608 1.25a18.27 18.27 0 0 0-5.487 0 12.64 12.64 0 0 0-.617-1.25.077.077 0 0 0-.079-.037A19.736 19.736 0 0 0 3.677 4.37a.07.07 0 0 0-.032.027C.533 9.046-.32 13.58.099 18.057a.082.082 0 0 0 .031.057 19.9 19.9 0 0 0 5.993 3.03.078.078 0 0 0 .084-.028c.462-.63.874-1.295 1.226-1.994a.076.076 0 0 0-.041-.106 13.107 13.107 0 0 1-1.872-.892.077.077 0 0 1-.008-.128 10.2 10.2 0 0 0 .372-.292.074.074 0 0 1 .077-.01c3.928 1.793 8.18 1.793 12.062 0a.074.074 0 0 1 .078.01c.12.098.246.198.373.292a.077.077 0 0 1-.006.127 12.299 12.299 0 0 1-1.873.892.077.077 0 0 0-.041.107c.36.698.772 1.362 1.225 1.993a.076.076 0 0 0 .084.028 19.839 19.839 0 0 0 6.002-3.03.077.077 0 0 0 .032-.054c.5-5.177-.838-9.674-3.549-13.66a.061.061 0 0 0-.031-.03zM8.02 15.33c-1.183 0-2.157-1.085-2.157-2.419 0-1.333.956-2.419 2.157-2.419 1.21 0 2.176 1.096 2.157 2.42 0 1.333-.956 2.418-2.157 2.418zm7.975 0c-1.183 0-2.157-1.085-2.157-2.419 0-1.333.955-2.419 2.157-2.419 1.21 0 2.176 1.096 2.157 2.42 0 1.333-.946 2.418-2.157 2.418z"/>`
2871
2934
  ),
2872
- gitlab: x(
2873
- h`<path fill="#FC6D26" d="m23.6 9.593-.033-.086L20.3.98a.851.851 0 0 0-.336-.405.876.876 0 0 0-1.001.054.874.874 0 0 0-.29.44l-2.205 6.748H7.535L5.33 1.069a.857.857 0 0 0-.29-.441.876.876 0 0 0-1.001-.054.86.86 0 0 0-.336.405L.436 9.502l-.032.086a6.066 6.066 0 0 0 2.012 7.01l.011.009.03.021 4.976 3.727 2.462 1.863 1.5 1.132a1.009 1.009 0 0 0 1.22 0l1.5-1.132 2.461-1.863 5.006-3.75.013-.01a6.068 6.068 0 0 0 2.006-7.002z"/>`
2935
+ gitlab: S(
2936
+ u`<path fill="#FC6D26" d="m23.6 9.593-.033-.086L20.3.98a.851.851 0 0 0-.336-.405.876.876 0 0 0-1.001.054.874.874 0 0 0-.29.44l-2.205 6.748H7.535L5.33 1.069a.857.857 0 0 0-.29-.441.876.876 0 0 0-1.001-.054.86.86 0 0 0-.336.405L.436 9.502l-.032.086a6.066 6.066 0 0 0 2.012 7.01l.011.009.03.021 4.976 3.727 2.462 1.863 1.5 1.132a1.009 1.009 0 0 0 1.22 0l1.5-1.132 2.461-1.863 5.006-3.75.013-.01a6.068 6.068 0 0 0 2.006-7.002z"/>`
2874
2937
  ),
2875
- linkedin: x(
2876
- h`<path fill="#0A66C2" d="M20.447 20.452h-3.554v-5.569c0-1.328-.027-3.037-1.852-3.037-1.853 0-2.136 1.445-2.136 2.939v5.667H9.351V9h3.414v1.561h.046c.477-.9 1.637-1.85 3.37-1.85 3.601 0 4.267 2.37 4.267 5.455v6.286zM5.337 7.433a2.062 2.062 0 0 1-2.063-2.065 2.064 2.064 0 1 1 2.063 2.065zm1.782 13.019H3.555V9h3.564v11.452zM22.225 0H1.771C.792 0 0 .774 0 1.729v20.542C0 23.227.792 24 1.771 24h20.451C23.2 24 24 23.227 24 22.271V1.729C24 .774 23.2 0 22.222 0h.003z"/>`
2938
+ linkedin: S(
2939
+ u`<path fill="#0A66C2" d="M20.447 20.452h-3.554v-5.569c0-1.328-.027-3.037-1.852-3.037-1.853 0-2.136 1.445-2.136 2.939v5.667H9.351V9h3.414v1.561h.046c.477-.9 1.637-1.85 3.37-1.85 3.601 0 4.267 2.37 4.267 5.455v6.286zM5.337 7.433a2.062 2.062 0 0 1-2.063-2.065 2.064 2.064 0 1 1 2.063 2.065zm1.782 13.019H3.555V9h3.564v11.452zM22.225 0H1.771C.792 0 0 .774 0 1.729v20.542C0 23.227.792 24 1.771 24h20.451C23.2 24 24 23.227 24 22.271V1.729C24 .774 23.2 0 22.222 0h.003z"/>`
2877
2940
  ),
2878
- slack: x(
2879
- h`<path fill="#E01E5A" d="M5.042 15.165a2.528 2.528 0 0 1-2.52 2.523A2.528 2.528 0 0 1 0 15.165a2.527 2.527 0 0 1 2.522-2.52h2.52v2.52zm1.271 0a2.527 2.527 0 0 1 2.521-2.52 2.527 2.527 0 0 1 2.521 2.52v6.313A2.528 2.528 0 0 1 8.834 24a2.528 2.528 0 0 1-2.521-2.522v-6.313z"/><path fill="#36C5F0" d="M8.834 5.042a2.528 2.528 0 0 1-2.521-2.52A2.528 2.528 0 0 1 8.834 0a2.528 2.528 0 0 1 2.521 2.522v2.52H8.834zm0 1.271a2.528 2.528 0 0 1 2.521 2.521 2.528 2.528 0 0 1-2.521 2.521H2.522A2.528 2.528 0 0 1 0 8.834a2.528 2.528 0 0 1 2.522-2.521h6.312z"/><path fill="#2EB67D" d="M18.956 8.834a2.528 2.528 0 0 1 2.522-2.521A2.528 2.528 0 0 1 24 8.834a2.528 2.528 0 0 1-2.522 2.521h-2.522V8.834zm-1.27 0a2.528 2.528 0 0 1-2.523 2.521 2.527 2.527 0 0 1-2.52-2.521V2.522A2.527 2.527 0 0 1 15.163 0a2.528 2.528 0 0 1 2.523 2.522v6.312z"/><path fill="#ECB22E" d="M15.163 18.956a2.528 2.528 0 0 1 2.523 2.522A2.528 2.528 0 0 1 15.163 24a2.527 2.527 0 0 1-2.52-2.522v-2.522h2.52zm0-1.27a2.527 2.527 0 0 1-2.52-2.523 2.526 2.526 0 0 1 2.52-2.52h6.315A2.527 2.527 0 0 1 24 15.163a2.528 2.528 0 0 1-2.522 2.523h-6.315z"/>`
2941
+ slack: S(
2942
+ u`<path fill="#E01E5A" d="M5.042 15.165a2.528 2.528 0 0 1-2.52 2.523A2.528 2.528 0 0 1 0 15.165a2.527 2.527 0 0 1 2.522-2.52h2.52v2.52zm1.271 0a2.527 2.527 0 0 1 2.521-2.52 2.527 2.527 0 0 1 2.521 2.52v6.313A2.528 2.528 0 0 1 8.834 24a2.528 2.528 0 0 1-2.521-2.522v-6.313z"/><path fill="#36C5F0" d="M8.834 5.042a2.528 2.528 0 0 1-2.521-2.52A2.528 2.528 0 0 1 8.834 0a2.528 2.528 0 0 1 2.521 2.522v2.52H8.834zm0 1.271a2.528 2.528 0 0 1 2.521 2.521 2.528 2.528 0 0 1-2.521 2.521H2.522A2.528 2.528 0 0 1 0 8.834a2.528 2.528 0 0 1 2.522-2.521h6.312z"/><path fill="#2EB67D" d="M18.956 8.834a2.528 2.528 0 0 1 2.522-2.521A2.528 2.528 0 0 1 24 8.834a2.528 2.528 0 0 1-2.522 2.521h-2.522V8.834zm-1.27 0a2.528 2.528 0 0 1-2.523 2.521 2.527 2.527 0 0 1-2.52-2.521V2.522A2.527 2.527 0 0 1 15.163 0a2.528 2.528 0 0 1 2.523 2.522v6.312z"/><path fill="#ECB22E" d="M15.163 18.956a2.528 2.528 0 0 1 2.523 2.522A2.528 2.528 0 0 1 15.163 24a2.527 2.527 0 0 1-2.52-2.522v-2.522h2.52zm0-1.27a2.527 2.527 0 0 1-2.52-2.523 2.526 2.526 0 0 1 2.52-2.52h6.315A2.527 2.527 0 0 1 24 15.163a2.528 2.528 0 0 1-2.522 2.523h-6.315z"/>`
2880
2943
  ),
2881
- twitch: x(
2882
- h`<path fill="#9146FF" d="M11.571 4.714h1.715v5.143H11.57zm4.715 0H18v5.143h-1.714zM6 0 1.714 4.286v15.428h5.143V24l4.286-4.286h3.428L22.286 12V0zm14.571 11.143-3.428 3.428h-3.429l-3 3v-3H6.857V1.714h13.714Z"/>`
2944
+ twitch: S(
2945
+ u`<path fill="#9146FF" d="M11.571 4.714h1.715v5.143H11.57zm4.715 0H18v5.143h-1.714zM6 0 1.714 4.286v15.428h5.143V24l4.286-4.286h3.428L22.286 12V0zm14.571 11.143-3.428 3.428h-3.429l-3 3v-3H6.857V1.714h13.714Z"/>`
2883
2946
  ),
2884
- spotify: x(
2885
- h`<path fill="#1DB954" d="M12 0C5.4 0 0 5.4 0 12s5.4 12 12 12 12-5.4 12-12S18.66 0 12 0zm5.521 17.34c-.24.359-.66.48-1.021.24-2.82-1.74-6.36-2.101-10.561-1.141-.418.122-.779-.179-.899-.539-.12-.421.18-.78.54-.9 4.56-1.021 8.52-.6 11.64 1.32.42.18.479.659.301 1.02zm1.44-3.3c-.301.42-.841.6-1.262.3-3.239-1.98-8.159-2.58-11.939-1.38-.479.12-1.02-.12-1.14-.6-.12-.48.12-1.021.6-1.141C9.6 9.9 15 10.561 18.72 12.84c.361.181.54.78.241 1.2zm.12-3.36C15.24 8.4 8.82 8.16 5.16 9.301c-.6.179-1.2-.181-1.38-.721-.18-.601.18-1.2.72-1.381 4.26-1.26 11.28-1.02 15.721 1.621.539.3.719 1.02.419 1.56-.299.421-1.02.599-1.559.3z"/>`
2947
+ spotify: S(
2948
+ u`<path fill="#1DB954" d="M12 0C5.4 0 0 5.4 0 12s5.4 12 12 12 12-5.4 12-12S18.66 0 12 0zm5.521 17.34c-.24.359-.66.48-1.021.24-2.82-1.74-6.36-2.101-10.561-1.141-.418.122-.779-.179-.899-.539-.12-.421.18-.78.54-.9 4.56-1.021 8.52-.6 11.64 1.32.42.18.479.659.301 1.02zm1.44-3.3c-.301.42-.841.6-1.262.3-3.239-1.98-8.159-2.58-11.939-1.38-.479.12-1.02-.12-1.14-.6-.12-.48.12-1.021.6-1.141C9.6 9.9 15 10.561 18.72 12.84c.361.181.54.78.241 1.2zm.12-3.36C15.24 8.4 8.82 8.16 5.16 9.301c-.6.179-1.2-.181-1.38-.721-.18-.601.18-1.2.72-1.381 4.26-1.26 11.28-1.02 15.721 1.621.539.3.719 1.02.419 1.56-.299.421-1.02.599-1.559.3z"/>`
2886
2949
  ),
2887
- notion: x(
2888
- h`<path fill="currentColor" d="M4.459 4.208c.746.606 1.026.56 2.428.466l13.215-.793c.28 0 .047-.28-.046-.326L17.86 1.968c-.42-.326-.981-.7-2.055-.607L3.01 2.295c-.466.046-.56.28-.374.466zm.793 3.08v13.904c0 .747.373 1.027 1.214.98l14.523-.84c.841-.046.935-.56.935-1.167V6.354c0-.606-.233-.933-.748-.887l-15.177.887c-.56.047-.747.327-.747.933zm14.337.745c.093.42 0 .84-.42.888l-.7.14v10.264c-.608.327-1.168.514-1.635.514-.748 0-.935-.234-1.495-.933l-4.577-7.186v6.952L12.21 19s0 .84-1.168.84l-3.222.186c-.093-.186 0-.653.327-.746l.84-.233V9.854L7.822 9.76c-.094-.42.14-1.026.793-1.073l3.456-.233 4.764 7.279v-6.44l-1.215-.139c-.093-.514.28-.887.747-.933zM1.936 1.035l13.31-.98c1.634-.14 2.055-.047 3.082.7l4.249 2.986c.7.513.934.653.934 1.213v16.378c0 1.026-.373 1.634-1.68 1.726l-15.458.934c-.98.047-1.448-.093-1.962-.747l-3.129-4.06c-.56-.747-.793-1.306-.793-1.96V2.667c0-.839.374-1.54 1.447-1.632z"/>`
2950
+ notion: S(
2951
+ u`<path fill="currentColor" d="M4.459 4.208c.746.606 1.026.56 2.428.466l13.215-.793c.28 0 .047-.28-.046-.326L17.86 1.968c-.42-.326-.981-.7-2.055-.607L3.01 2.295c-.466.046-.56.28-.374.466zm.793 3.08v13.904c0 .747.373 1.027 1.214.98l14.523-.84c.841-.046.935-.56.935-1.167V6.354c0-.606-.233-.933-.748-.887l-15.177.887c-.56.047-.747.327-.747.933zm14.337.745c.093.42 0 .84-.42.888l-.7.14v10.264c-.608.327-1.168.514-1.635.514-.748 0-.935-.234-1.495-.933l-4.577-7.186v6.952L12.21 19s0 .84-1.168.84l-3.222.186c-.093-.186 0-.653.327-.746l.84-.233V9.854L7.822 9.76c-.094-.42.14-1.026.793-1.073l3.456-.233 4.764 7.279v-6.44l-1.215-.139c-.093-.514.28-.887.747-.933zM1.936 1.035l13.31-.98c1.634-.14 2.055-.047 3.082.7l4.249 2.986c.7.513.934.653.934 1.213v16.378c0 1.026-.373 1.634-1.68 1.726l-15.458.934c-.98.047-1.448-.093-1.962-.747l-3.129-4.06c-.56-.747-.793-1.306-.793-1.96V2.667c0-.839.374-1.54 1.447-1.632z"/>`
2889
2952
  ),
2890
- dropbox: x(
2891
- h`<path fill="#0061FF" d="M6 1.807 0 5.629l6 3.822 6.001-3.822L6 1.807zm12 0-6 3.822 6 3.822 6-3.822-6-3.822zM0 13.274l6 3.822 6.001-3.822L6 9.452l-6 3.822zm18-3.822-6 3.822 6 3.822 6-3.822-6-3.822zM6 18.371l6.001 3.822 6-3.822-6-3.822L6 18.371z"/>`
2953
+ dropbox: S(
2954
+ u`<path fill="#0061FF" d="M6 1.807 0 5.629l6 3.822 6.001-3.822L6 1.807zm12 0-6 3.822 6 3.822 6-3.822-6-3.822zM0 13.274l6 3.822 6.001-3.822L6 9.452l-6 3.822zm18-3.822-6 3.822 6 3.822 6-3.822-6-3.822zM6 18.371l6.001 3.822 6-3.822-6-3.822L6 18.371z"/>`
2892
2955
  ),
2893
- figma: x(
2894
- h`<path fill="#F24E1E" d="M8 24a4 4 0 0 0 4-4v-4H8a4 4 0 0 0 0 8z"/><path fill="#A259FF" d="M4 12a4 4 0 0 1 4-4h4v8H8a4 4 0 0 1-4-4z"/><path fill="#FF7262" d="M4 4a4 4 0 0 1 4-4h4v8H8a4 4 0 0 1-4-4z"/><path fill="#1ABCFE" d="M12 0h4a4 4 0 0 1 0 8h-4V0z"/><path fill="#0ACF83" d="M20 12a4 4 0 1 1-8 0 4 4 0 0 1 8 0z"/>`
2956
+ figma: S(
2957
+ u`<path fill="#F24E1E" d="M8 24a4 4 0 0 0 4-4v-4H8a4 4 0 0 0 0 8z"/><path fill="#A259FF" d="M4 12a4 4 0 0 1 4-4h4v8H8a4 4 0 0 1-4-4z"/><path fill="#FF7262" d="M4 4a4 4 0 0 1 4-4h4v8H8a4 4 0 0 1-4-4z"/><path fill="#1ABCFE" d="M12 0h4a4 4 0 0 1 0 8h-4V0z"/><path fill="#0ACF83" d="M20 12a4 4 0 1 1-8 0 4 4 0 0 1 8 0z"/>`
2895
2958
  ),
2896
- bitbucket: x(
2897
- h`<path fill="#2684FF" d="M.778 1.213a.768.768 0 0 0-.768.892l3.263 19.81c.084.5.515.868 1.022.873H19.95a.772.772 0 0 0 .77-.646l3.27-20.03a.768.768 0 0 0-.768-.891zM14.52 15.53H9.522L8.17 8.466h7.561z"/>`
2959
+ bitbucket: S(
2960
+ u`<path fill="#2684FF" d="M.778 1.213a.768.768 0 0 0-.768.892l3.263 19.81c.084.5.515.868 1.022.873H19.95a.772.772 0 0 0 .77-.646l3.27-20.03a.768.768 0 0 0-.768-.891zM14.52 15.53H9.522L8.17 8.466h7.561z"/>`
2898
2961
  ),
2899
- amazon: x(
2900
- h`<path fill="currentColor" d="M.045 18.02c.072-.116.187-.124.348-.022 3.636 2.11 7.594 3.166 11.87 3.166 2.852 0 5.668-.533 8.447-1.595l.315-.14c.138-.06.234-.1.293-.13.226-.088.39-.046.525.13.12.174.09.336-.12.48-.256.19-.6.41-1.006.654-1.244.743-2.64 1.316-4.185 1.726a17.617 17.617 0 0 1-10.951-.577 17.88 17.88 0 0 1-5.43-3.35c-.1-.074-.151-.15-.151-.22 0-.047.021-.09.051-.13zm6.565-6.218c0-1.005.247-1.863.743-2.577.495-.71 1.17-1.25 2.04-1.615.796-.335 1.756-.575 2.912-.72.39-.046 1.033-.103 1.92-.174v-.37c0-.93-.105-1.558-.3-1.875-.302-.43-.78-.65-1.44-.65h-.182c-.48.046-.896.196-1.246.46-.35.27-.575.63-.675 1.096-.06.3-.206.465-.435.51l-2.52-.315c-.248-.06-.372-.18-.372-.39 0-.046.007-.09.022-.15.247-1.29.855-2.25 1.82-2.88.976-.616 2.1-.975 3.39-1.05h.54c1.65 0 2.957.434 3.888 1.29.135.15.27.3.405.48.12.165.224.314.283.45.075.134.15.33.195.57.06.254.105.42.135.51.03.104.062.3.076.615.01.313.02.493.02.553v5.28c0 .376.06.72.165 1.036.105.313.21.54.315.674l.51.674c.09.136.136.256.136.36 0 .12-.06.226-.18.314-1.2 1.05-1.86 1.62-1.963 1.71-.165.135-.373.15-.61.045a6.62 6.62 0 0 1-.526-.496l-.31-.347a9.858 9.858 0 0 1-.317-.42l-.3-.435c-.81.886-1.603 1.44-2.4 1.665-.494.15-1.093.227-1.83.227-1.11 0-2.04-.343-2.76-1.034-.72-.69-1.08-1.665-1.08-2.94l-.05-.076zm3.753-.438c0 .566.14 1.02.425 1.364.285.34.675.512 1.155.512.045 0 .106-.007.195-.02.09-.016.134-.023.166-.023.614-.16 1.08-.553 1.424-1.178.165-.28.285-.58.36-.91.09-.32.12-.59.135-.8.015-.195.015-.54.015-1.005v-.54c-.84 0-1.484.06-1.92.18-1.275.36-1.92 1.17-1.92 2.43l-.035-.01zm9.162 7.027c.03-.06.075-.11.132-.17.362-.243.714-.41 1.05-.5a8.094 8.094 0 0 1 1.612-.24c.14-.012.28 0 .41.03.65.06 1.05.168 1.172.33.063.09.099.228.099.39v.15c0 .51-.149 1.11-.424 1.8-.278.69-.664 1.248-1.156 1.68-.073.06-.14.09-.197.09-.03 0-.06 0-.09-.012-.09-.044-.107-.12-.064-.24.54-1.26.806-2.143.806-2.64 0-.15-.03-.27-.087-.344-.145-.166-.55-.257-1.224-.257-.243 0-.533.016-.87.045-.363.045-.7.09-1 .135-.09 0-.148-.014-.18-.044-.03-.03-.036-.06-.02-.106 0-.014.007-.03.02-.06z"/>`
2962
+ amazon: S(
2963
+ u`<path fill="currentColor" d="M.045 18.02c.072-.116.187-.124.348-.022 3.636 2.11 7.594 3.166 11.87 3.166 2.852 0 5.668-.533 8.447-1.595l.315-.14c.138-.06.234-.1.293-.13.226-.088.39-.046.525.13.12.174.09.336-.12.48-.256.19-.6.41-1.006.654-1.244.743-2.64 1.316-4.185 1.726a17.617 17.617 0 0 1-10.951-.577 17.88 17.88 0 0 1-5.43-3.35c-.1-.074-.151-.15-.151-.22 0-.047.021-.09.051-.13zm6.565-6.218c0-1.005.247-1.863.743-2.577.495-.71 1.17-1.25 2.04-1.615.796-.335 1.756-.575 2.912-.72.39-.046 1.033-.103 1.92-.174v-.37c0-.93-.105-1.558-.3-1.875-.302-.43-.78-.65-1.44-.65h-.182c-.48.046-.896.196-1.246.46-.35.27-.575.63-.675 1.096-.06.3-.206.465-.435.51l-2.52-.315c-.248-.06-.372-.18-.372-.39 0-.046.007-.09.022-.15.247-1.29.855-2.25 1.82-2.88.976-.616 2.1-.975 3.39-1.05h.54c1.65 0 2.957.434 3.888 1.29.135.15.27.3.405.48.12.165.224.314.283.45.075.134.15.33.195.57.06.254.105.42.135.51.03.104.062.3.076.615.01.313.02.493.02.553v5.28c0 .376.06.72.165 1.036.105.313.21.54.315.674l.51.674c.09.136.136.256.136.36 0 .12-.06.226-.18.314-1.2 1.05-1.86 1.62-1.963 1.71-.165.135-.373.15-.61.045a6.62 6.62 0 0 1-.526-.496l-.31-.347a9.858 9.858 0 0 1-.317-.42l-.3-.435c-.81.886-1.603 1.44-2.4 1.665-.494.15-1.093.227-1.83.227-1.11 0-2.04-.343-2.76-1.034-.72-.69-1.08-1.665-1.08-2.94l-.05-.076zm3.753-.438c0 .566.14 1.02.425 1.364.285.34.675.512 1.155.512.045 0 .106-.007.195-.02.09-.016.134-.023.166-.023.614-.16 1.08-.553 1.424-1.178.165-.28.285-.58.36-.91.09-.32.12-.59.135-.8.015-.195.015-.54.015-1.005v-.54c-.84 0-1.484.06-1.92.18-1.275.36-1.92 1.17-1.92 2.43l-.035-.01zm9.162 7.027c.03-.06.075-.11.132-.17.362-.243.714-.41 1.05-.5a8.094 8.094 0 0 1 1.612-.24c.14-.012.28 0 .41.03.65.06 1.05.168 1.172.33.063.09.099.228.099.39v.15c0 .51-.149 1.11-.424 1.8-.278.69-.664 1.248-1.156 1.68-.073.06-.14.09-.197.09-.03 0-.06 0-.09-.012-.09-.044-.107-.12-.064-.24.54-1.26.806-2.143.806-2.64 0-.15-.03-.27-.087-.344-.145-.166-.55-.257-1.224-.257-.243 0-.533.016-.87.045-.363.045-.7.09-1 .135-.09 0-.148-.014-.18-.044-.03-.03-.036-.06-.02-.106 0-.014.007-.03.02-.06z"/>`
2901
2964
  ),
2902
- paypal: x(
2903
- h`<path fill="#003087" d="M7.076 21.337H2.47a.641.641 0 0 1-.633-.74L4.944.901C5.026.382 5.474 0 5.998 0h7.46c2.57 0 4.578.543 5.69 1.81 1.01 1.15 1.304 2.42 1.012 4.287-.023.143-.047.288-.077.437-.983 5.05-4.349 6.797-8.647 6.797h-2.19c-.524 0-.968.382-1.05.9l-1.12 7.106zm14.146-14.42a3.35 3.35 0 0 0-.607-.541c-.013.076-.026.175-.041.254-.93 4.778-4.005 7.201-9.138 7.201h-2.19a.563.563 0 0 0-.556.479l-1.187 7.527h-.506l-.24 1.516a.56.56 0 0 0 .554.647h3.882c.46 0 .85-.334.922-.788.06-.26.76-4.852.816-5.09a.932.932 0 0 1 .923-.788h.58c3.76 0 6.705-1.528 7.565-5.946.36-1.847.174-3.388-.777-4.471z"/>`
2965
+ paypal: S(
2966
+ u`<path fill="#003087" d="M7.076 21.337H2.47a.641.641 0 0 1-.633-.74L4.944.901C5.026.382 5.474 0 5.998 0h7.46c2.57 0 4.578.543 5.69 1.81 1.01 1.15 1.304 2.42 1.012 4.287-.023.143-.047.288-.077.437-.983 5.05-4.349 6.797-8.647 6.797h-2.19c-.524 0-.968.382-1.05.9l-1.12 7.106zm14.146-14.42a3.35 3.35 0 0 0-.607-.541c-.013.076-.026.175-.041.254-.93 4.778-4.005 7.201-9.138 7.201h-2.19a.563.563 0 0 0-.556.479l-1.187 7.527h-.506l-.24 1.516a.56.56 0 0 0 .554.647h3.882c.46 0 .85-.334.922-.788.06-.26.76-4.852.816-5.09a.932.932 0 0 1 .923-.788h.58c3.76 0 6.705-1.528 7.565-5.946.36-1.847.174-3.388-.777-4.471z"/>`
2904
2967
  )
2905
2968
  };
2906
- function Y(e) {
2907
- return Kt[e] ?? l.globe;
2969
+ function B(e) {
2970
+ return Gt[e] ?? l.globe;
2908
2971
  }
2909
- function nt(e) {
2972
+ function lt(e) {
2910
2973
  const t = (e.trim()[0] ?? "?").toUpperCase();
2911
2974
  return /[A-Z0-9]/i.test(t) ? t : l.user;
2912
2975
  }
2913
- function Z(e) {
2976
+ function X(e) {
2914
2977
  typeof document > "u" || (document.querySelector("authui-modal") || document.body.appendChild(document.createElement("authui-modal")), queueMicrotask(() => {
2915
2978
  window.dispatchEvent(new CustomEvent("authui:open", { detail: { view: e } }));
2916
2979
  }));
2917
2980
  }
2918
- function ce() {
2981
+ function de() {
2919
2982
  typeof window > "u" || window.dispatchEvent(new CustomEvent("authui:close"));
2920
2983
  }
2921
- function it(e) {
2984
+ function rt(e) {
2922
2985
  const t = {
2923
2986
  length: e.length >= 8,
2924
2987
  long: e.length >= 12,
@@ -2934,29 +2997,33 @@ function it(e) {
2934
2997
  let s, a;
2935
2998
  return !t.length || i <= 1 ? (s = 1, a = "passwordStrengthTooWeak") : i === 2 ? (s = 2, a = "passwordStrengthWeak") : i === 3 ? (s = 3, a = "passwordStrengthFair") : i >= 5 && t.long && t.lower && t.upper && t.number && t.symbol ? (s = 4, a = "passwordStrengthVeryStrong") : (s = 4, a = "passwordStrengthStrong"), { level: s, percent: s * 25, labelKey: a, checks: t };
2936
2999
  }
2937
- var Gt = Object.defineProperty, Yt = Object.getOwnPropertyDescriptor, C = (e, t, i, s) => {
2938
- for (var a = s > 1 ? void 0 : s ? Yt(t, i) : t, c = e.length - 1, u; c >= 0; c--)
2939
- (u = e[c]) && (a = (s ? u(t, i, a) : u(a)) || a);
2940
- return s && a && Gt(t, i, a), a;
3000
+ var Yt = Object.defineProperty, Zt = Object.getOwnPropertyDescriptor, k = (e, t, i, s) => {
3001
+ for (var a = s > 1 ? void 0 : s ? Zt(t, i) : t, h = e.length - 1, d; h >= 0; h--)
3002
+ (d = e[h]) && (a = (s ? d(t, i, a) : d(a)) || a);
3003
+ return s && a && Yt(t, i, a), a;
2941
3004
  };
2942
- let k = class extends E {
3005
+ let $ = class extends U {
2943
3006
  constructor() {
2944
- super(...arguments), this.view = "sign-in", this.embedded = !1, this.step = "sign-in", this.busy = !1, this.error = "", this.notice = null, this.showPassword = !1, this.expandedOAuth = null, this.token = null, this.focusOnStep = !1, this.resendCooldownUntil = 0, this.challenge = null, this.recovery = null, this.email = "", this.password = "", this.passwordConfirm = "", this.name = "", this.phone = "", this.code = "", this.onSignIn = (e) => {
3007
+ super(...arguments), this.view = "sign-in", this.embedded = !1, this.step = "sign-in", this.busy = !1, this.error = "", this.notice = null, this.showPassword = !1, this.showPasswordConfirm = !1, this.expandedOAuth = null, this.token = null, this.focusOnStep = !1, this.resendCooldownUntil = 0, this.challenge = null, this.recovery = null, this.email = "", this.password = "", this.passwordConfirm = "", this.name = "", this.phone = "", this.code = "", this.legalAccepted = !1, this.legalErrorFromOAuth = !1, this.onSignIn = (e) => {
2945
3008
  e.preventDefault(), this.requireValid(e) && this.run(async () => {
2946
- await o.signInWithEmailPassword(this.email, this.password), this.password = "", V("email-password"), this.fire("authui-success", { method: "email-password" });
3009
+ await o.signInWithEmailPassword(this.email, this.password), this.password = "", _("email-password"), this.fire("authui-success", { method: "email-password" });
2947
3010
  });
2948
3011
  }, this.onSignUp = (e) => {
2949
- e.preventDefault(), this.requireValid(e) && this.run(async () => {
2950
- await o.signUp(this.email, this.password, this.name), this.password = "", V("email-password"), this.fire("authui-success", { method: "sign-up" });
2951
- });
3012
+ e.preventDefault(), this.requireValid(e) && (this.legalErrorFromOAuth = !1, this.ensureLegalAccepted() && this.run(async () => {
3013
+ await o.signUp(this.email, this.password, this.name), this.password = "", _("email-password"), this.fire("authui-success", { method: "sign-up" });
3014
+ }));
2952
3015
  }, this.onGuest = () => {
2953
3016
  this.run(async () => {
2954
- await o.signInAnonymously(), V("anonymous"), this.fire("authui-success", { method: "anonymous" });
3017
+ await o.signInAnonymously(), _("anonymous"), this.fire("authui-success", { method: "anonymous" });
2955
3018
  });
2956
3019
  }, this.onOAuth = (e) => {
2957
- this.run(async () => {
2958
- if (Ot(e), await o.signInWithOAuth(e), o.isPreview) {
2959
- wt(), this.fire("authui-success", { method: "oauth" });
3020
+ if (this.step === "sign-up" && !this.ensureLegalAccepted()) {
3021
+ this.legalErrorFromOAuth = !0;
3022
+ return;
3023
+ }
3024
+ this.legalErrorFromOAuth = !1, this.run(async () => {
3025
+ if (Ft(e), await o.signInWithOAuth(e), o.isPreview) {
3026
+ $t(), this.fire("authui-success", { method: "oauth" });
2960
3027
  return;
2961
3028
  }
2962
3029
  await new Promise((t) => setTimeout(t, 4e3));
@@ -2993,18 +3060,18 @@ let k = class extends E {
2993
3060
  kind: "email-otp",
2994
3061
  target: this.email,
2995
3062
  phrase: t.phrase
2996
- }, this.code = "";
3063
+ }, this.code = "", this.resendCooldownUntil = Date.now() + 3e4, window.setTimeout(() => this.requestUpdate(), 3e4);
2997
3064
  });
2998
3065
  }, this.onPhoneOtp = (e) => {
2999
3066
  e.preventDefault(), this.requireValid(e) && this.run(async () => {
3000
3067
  const t = await o.sendPhoneOtp(this.phone);
3001
- this.token = { userId: t.userId, kind: "phone", target: this.phone }, this.code = "";
3068
+ this.token = { userId: t.userId, kind: "phone", target: this.phone }, this.code = "", this.resendCooldownUntil = Date.now() + 3e4, window.setTimeout(() => this.requestUpdate(), 3e4);
3002
3069
  });
3003
3070
  }, this.onVerifyCode = (e) => {
3004
3071
  if (e.preventDefault(), !this.requireValid(e)) return;
3005
3072
  const t = this.token;
3006
3073
  t && this.run(async () => {
3007
- await o.signInWithToken(t.userId, this.code), this.code = "", this.token = null, V(t.kind), this.fire("authui-success", { method: t.kind });
3074
+ await o.signInWithToken(t.userId, this.code), this.code = "", this.token = null, _(t.kind), this.fire("authui-success", { method: t.kind });
3008
3075
  }, "code");
3009
3076
  }, this.onChooseFactor = (e) => {
3010
3077
  this.run(async () => {
@@ -3022,7 +3089,7 @@ let k = class extends E {
3022
3089
  try {
3023
3090
  await o.signOut();
3024
3091
  } catch (e) {
3025
- if (!q(e, f.sessionNotFound)) throw e;
3092
+ if (!j(e, v.sessionNotFound)) throw e;
3026
3093
  }
3027
3094
  this.go("sign-in");
3028
3095
  });
@@ -3054,7 +3121,7 @@ let k = class extends E {
3054
3121
  this.notice = null, this.auth.pending?.type === "notice" && o.setPending(null);
3055
3122
  }
3056
3123
  go(e) {
3057
- e === "sign-up" && this.config?.signUp === !1 && (e = "sign-in"), this.focusOnStep = !0, this.step = e, this.error = "", this.notice = null, this.busy = !1, this.showPassword = !1, this.password = "", this.passwordConfirm = "", e !== "mfa" && (this.challenge = null), e !== "email-otp" && e !== "phone" && e !== "magic-url" && (this.token = null), this.fire("authui-view", { view: e });
3124
+ e === "sign-up" && this.config?.signUp === !1 && (e = "sign-in"), this.focusOnStep = !0, this.step = e, this.error = "", this.notice = null, this.busy = !1, this.showPassword = !1, this.showPasswordConfirm = !1, this.password = "", this.passwordConfirm = "", this.legalAccepted = !1, this.legalErrorFromOAuth = !1, e !== "mfa" && (this.challenge = null), e !== "email-otp" && e !== "phone" && e !== "magic-url" && (this.token = null), this.fire("authui-view", { view: e });
3058
3125
  }
3059
3126
  // ───────────────────────────── actions ─────────────────────────────
3060
3127
  async run(e, t = "link") {
@@ -3063,7 +3130,7 @@ let k = class extends E {
3063
3130
  try {
3064
3131
  await e();
3065
3132
  } catch (i) {
3066
- this.error = K(i, this.strings, t);
3133
+ this.error = Y(i, this.strings, t);
3067
3134
  } finally {
3068
3135
  this.busy = !1;
3069
3136
  }
@@ -3156,7 +3223,7 @@ let k = class extends E {
3156
3223
  </button>`;
3157
3224
  }
3158
3225
  passwordField(e) {
3159
- const t = this[e.field], i = e.meter ? it(t) : null;
3226
+ const t = this[e.field], i = e.field === "passwordConfirm" ? this.showPasswordConfirm : this.showPassword, s = e.meter ? rt(t) : null;
3160
3227
  return r`
3161
3228
  <div class="field">
3162
3229
  <div class="field-header">
@@ -3173,7 +3240,7 @@ let k = class extends E {
3173
3240
  <input
3174
3241
  class="input"
3175
3242
  id=${e.id}
3176
- type=${this.showPassword ? "text" : "password"}
3243
+ type=${i ? "text" : "password"}
3177
3244
  autocomplete=${e.autocomplete}
3178
3245
  required
3179
3246
  minlength="8"
@@ -3183,26 +3250,28 @@ let k = class extends E {
3183
3250
  <button
3184
3251
  type="button"
3185
3252
  class="btn btn-ghost btn-icon"
3186
- @click=${() => this.showPassword = !this.showPassword}
3187
- aria-label=${this.showPassword ? this.t("hidePassword") : this.t("showPassword")}
3253
+ @click=${() => {
3254
+ e.field === "passwordConfirm" ? this.showPasswordConfirm = !this.showPasswordConfirm : this.showPassword = !this.showPassword;
3255
+ }}
3256
+ aria-label=${i ? this.t("hidePassword") : this.t("showPassword")}
3188
3257
  >
3189
- ${this.showPassword ? l.eyeOff : l.eye}
3258
+ ${i ? l.eyeOff : l.eye}
3190
3259
  </button>
3191
3260
  </div>
3192
- ${i && t ? r`<div class="strength" aria-live="polite">
3261
+ ${s && t ? r`<div class="strength" aria-live="polite">
3193
3262
  <div
3194
3263
  class="strength-meter"
3195
- data-level=${String(i.level)}
3264
+ data-level=${String(s.level)}
3196
3265
  role="meter"
3197
3266
  aria-label=${this.t("passwordStrengthLabel")}
3198
3267
  aria-valuemin="0"
3199
3268
  aria-valuemax="4"
3200
- aria-valuenow=${String(i.level)}
3201
- aria-valuetext=${this.t(i.labelKey)}
3269
+ aria-valuenow=${String(s.level)}
3270
+ aria-valuetext=${this.t(s.labelKey)}
3202
3271
  >
3203
3272
  <span></span><span></span><span></span><span></span>
3204
3273
  </div>
3205
- <p class="strength-label">${this.t(i.labelKey)}</p>
3274
+ <p class="strength-label">${this.t(s.labelKey)}</p>
3206
3275
  </div>` : e.hint ? r`<p class="hint">${e.hint}</p>` : n}
3207
3276
  </div>
3208
3277
  `;
@@ -3243,14 +3312,35 @@ let k = class extends E {
3243
3312
  </div>
3244
3313
  `;
3245
3314
  }
3315
+ /** True when sign-up must show/enforce the legal checkbox. */
3316
+ needsLegalAcceptance() {
3317
+ const e = this.config?.legal;
3318
+ return e?.requireAcceptance ? !!(e.termsUrl || e.privacyUrl) : !1;
3319
+ }
3320
+ /** Block sign-up / OAuth when the required legal checkbox is unchecked. */
3321
+ ensureLegalAccepted() {
3322
+ return !this.needsLegalAcceptance() || this.legalAccepted ? !0 : (this.error = this.t("errorLegalRequired"), !1);
3323
+ }
3324
+ legalLinks() {
3325
+ const e = this.config?.legal;
3326
+ return !e?.termsUrl && !e?.privacyUrl ? n : r`${e.termsUrl ? r`<a href=${e.termsUrl} target="_blank" rel="noopener">${this.t("terms")}</a>` : n}${e.termsUrl && e.privacyUrl ? r` ${this.t("and")} ` : n}${e.privacyUrl ? r`<a href=${e.privacyUrl} target="_blank" rel="noopener">${this.t("privacy")}</a>` : n}`;
3327
+ }
3246
3328
  legal() {
3247
3329
  const e = this.config?.legal;
3248
- return !e?.termsUrl && !e?.privacyUrl ? n : r`<p class="legal">
3249
- ${this.t("agreeTo")}
3250
- ${e.termsUrl ? r`<a href=${e.termsUrl} target="_blank" rel="noopener">${this.t("terms")}</a>` : n}
3251
- ${e.termsUrl && e.privacyUrl ? r` ${this.t("and")} ` : n}
3252
- ${e.privacyUrl ? r`<a href=${e.privacyUrl} target="_blank" rel="noopener">${this.t("privacy")}</a>` : n}.
3253
- </p>`;
3330
+ return !e?.termsUrl && !e?.privacyUrl ? n : this.step === "sign-up" && this.needsLegalAcceptance() ? n : r`<p class="legal">${this.t("agreeTo")} ${this.legalLinks()}.</p>`;
3331
+ }
3332
+ /** Required acceptance checkbox on sign-up when legal.requireAcceptance is set. */
3333
+ legalAcceptField() {
3334
+ return this.needsLegalAcceptance() ? r`<label class="legal-accept">
3335
+ <input
3336
+ type="checkbox"
3337
+ .checked=${this.legalAccepted}
3338
+ @change=${(e) => {
3339
+ this.legalAccepted = e.target.checked, this.legalAccepted && this.error === this.t("errorLegalRequired") && (this.error = "", this.legalErrorFromOAuth = !1);
3340
+ }}
3341
+ />
3342
+ <span>${this.t("acceptLegal")} ${this.legalLinks()}.</span>
3343
+ </label>` : n;
3254
3344
  }
3255
3345
  backLink(e = "sign-in") {
3256
3346
  return r`<div class="links">
@@ -3298,7 +3388,7 @@ let k = class extends E {
3298
3388
  <div class="stack">
3299
3389
  <div class="row">
3300
3390
  <div class="inline">
3301
- <span class="avatar">${nt(t)}</span>
3391
+ <span class="avatar">${lt(t)}</span>
3302
3392
  <div class="row-main">
3303
3393
  <span class="row-title" title=${t}>${t}</span>
3304
3394
  ${e.email && e.name ? r`<span class="row-sub" title=${e.email}>${e.email}</span>` : n}
@@ -3313,7 +3403,7 @@ let k = class extends E {
3313
3403
  <button
3314
3404
  class="btn btn-outline btn-block"
3315
3405
  @click=${() => {
3316
- this.embedded ? this.fire("authui-open", { view: "account" }) : Z("account");
3406
+ this.embedded ? this.fire("authui-open", { view: "account" }) : X("account");
3317
3407
  }}
3318
3408
  >
3319
3409
  ${l.settings} ${this.t("manageAccount")}
@@ -3328,32 +3418,56 @@ let k = class extends E {
3328
3418
  renderProviders() {
3329
3419
  const e = [...this.config?.methods?.oauth ?? []];
3330
3420
  if (e.length === 0) return n;
3331
- const t = z(), i = e.find((a) => t === `oauth:${a}`) ?? null;
3332
- if (e.length <= 2) {
3333
- const a = [...e].sort((c, u) => {
3334
- const b = t === `oauth:${c}` ? 0 : 1, $ = t === `oauth:${u}` ? 0 : 1;
3335
- return b - $;
3421
+ const t = z(), i = e.find((d) => t === `oauth:${d}`) ?? null, s = this.config?.methods?.oauthLayout, a = s === "horizontal" || s === "icon" ? "icon" : s === "stack" || s === "accordion" ? s : e.length <= 2 ? "stack" : "accordion";
3422
+ if (a === "icon") {
3423
+ const d = [...e].sort((g, y) => {
3424
+ const C = t === `oauth:${g}` ? 0 : 1, tt = t === `oauth:${y}` ? 0 : 1;
3425
+ return C - tt;
3426
+ });
3427
+ return r`
3428
+ <div class="providers icon">
3429
+ ${d.map((g) => {
3430
+ const y = t === `oauth:${g}`, C = this.t("continueWith", { provider: N(g) });
3431
+ return r`<button
3432
+ type="button"
3433
+ class="btn btn-outline ${y ? "last-used" : ""}"
3434
+ @click=${() => this.onOAuth(g)}
3435
+ ?disabled=${this.busy}
3436
+ aria-label=${y ? `${C}. ${this.t("lastUsed")}` : C}
3437
+ title=${C}
3438
+ >
3439
+ ${B(g)}
3440
+ ${y ? r`<span class="oauth-last-used-dot" aria-hidden="true"></span>` : n}
3441
+ </button>`;
3442
+ })}
3443
+ </div>
3444
+ `;
3445
+ }
3446
+ if (a === "stack") {
3447
+ const d = [...e].sort((g, y) => {
3448
+ const C = t === `oauth:${g}` ? 0 : 1, tt = t === `oauth:${y}` ? 0 : 1;
3449
+ return C - tt;
3336
3450
  });
3337
3451
  return r`
3338
3452
  <div class="providers">
3339
- ${a.map((c) => {
3340
- const u = t === `oauth:${c}`, b = this.t("continueWith", { provider: W(c) });
3453
+ ${d.map((g) => {
3454
+ const y = t === `oauth:${g}`, C = this.t("continueWith", { provider: N(g) });
3341
3455
  return r`<button
3342
3456
  type="button"
3343
- class="btn btn-outline ${u ? "last-used" : ""}"
3344
- @click=${() => this.onOAuth(c)}
3457
+ class="btn btn-outline ${y ? "last-used" : ""}"
3458
+ @click=${() => this.onOAuth(g)}
3345
3459
  ?disabled=${this.busy}
3346
- aria-label=${u ? `${b}. ${this.t("lastUsed")}` : b}
3460
+ aria-label=${y ? `${C}. ${this.t("lastUsed")}` : C}
3347
3461
  >
3348
- ${Y(c)}
3349
- <span>${b}</span>
3350
- ${u ? r`<span class="last-used-badge">${this.t("lastUsed")}</span>` : n}
3462
+ ${B(g)}
3463
+ <span>${C}</span>
3464
+ ${y ? r`<span class="last-used-badge">${this.t("lastUsed")}</span>` : n}
3351
3465
  </button>`;
3352
3466
  })}
3353
3467
  </div>
3354
3468
  `;
3355
3469
  }
3356
- const s = this.expandedOAuth && e.includes(this.expandedOAuth) ? this.expandedOAuth : i ?? e[0];
3470
+ const h = this.expandedOAuth && e.includes(this.expandedOAuth) ? this.expandedOAuth : i ?? e[0];
3357
3471
  return r`
3358
3472
  <div
3359
3473
  class="providers accordion"
@@ -3361,29 +3475,29 @@ let k = class extends E {
3361
3475
  this.expandedOAuth = i ?? e[0];
3362
3476
  }}
3363
3477
  >
3364
- ${e.map((a) => {
3365
- const c = t === `oauth:${a}`, u = s === a, b = this.t("continueWith", { provider: W(a) });
3478
+ ${e.map((d) => {
3479
+ const g = t === `oauth:${d}`, y = h === d, C = this.t("continueWith", { provider: N(d) });
3366
3480
  return r`<div
3367
- class="provider-slot ${u ? "is-expanded" : ""}"
3481
+ class="provider-slot ${y ? "is-expanded" : ""}"
3368
3482
  @mouseenter=${() => {
3369
- this.expandedOAuth = a;
3483
+ this.expandedOAuth = d;
3370
3484
  }}
3371
3485
  >
3372
3486
  <button
3373
3487
  type="button"
3374
3488
  class="btn btn-outline"
3375
- @click=${() => this.onOAuth(a)}
3489
+ @click=${() => this.onOAuth(d)}
3376
3490
  @focus=${() => {
3377
- this.expandedOAuth = a;
3491
+ this.expandedOAuth = d;
3378
3492
  }}
3379
3493
  ?disabled=${this.busy}
3380
- aria-label=${c ? `${b}. ${this.t("lastUsed")}` : b}
3494
+ aria-label=${g ? `${C}. ${this.t("lastUsed")}` : C}
3381
3495
  >
3382
- ${Y(a)}
3496
+ ${B(d)}
3383
3497
  <span class="provider-label"
3384
- ><span><span class="provider-label-text">${b}</span></span></span
3498
+ ><span><span class="provider-label-text">${C}</span></span></span
3385
3499
  >
3386
- ${c ? r`<span class="oauth-last-used" data-last-used=${a} aria-hidden="true">
3500
+ ${g ? r`<span class="oauth-last-used" data-last-used=${d} aria-hidden="true">
3387
3501
  <span class="oauth-last-used-dot"></span>
3388
3502
  <span class="oauth-last-used-pill">${this.t("lastUsed")}</span>
3389
3503
  </span>` : n}
@@ -3417,14 +3531,15 @@ let k = class extends E {
3417
3531
  </form>` : this.renderError()}
3418
3532
  ${s.length > 0 ? r`<div class="stack-sm">
3419
3533
  ${s.map((a) => {
3420
- const c = z() === a.step;
3534
+ const h = z() === a.step;
3421
3535
  return r`<button
3422
3536
  type="button"
3423
- class="btn btn-secondary btn-block ${c ? "last-used" : ""}"
3537
+ class="btn btn-secondary btn-block ${h ? "last-used" : ""}"
3424
3538
  @click=${() => this.go(a.step)}
3539
+ ?disabled=${this.busy}
3425
3540
  >
3426
3541
  ${a.icon} ${a.label}
3427
- ${c ? r`<span class="last-used-badge">${this.t("lastUsed")}</span>` : n}
3542
+ ${h ? r`<span class="last-used-badge">${this.t("lastUsed")}</span>` : n}
3428
3543
  </button>`;
3429
3544
  })}
3430
3545
  </div>` : n}
@@ -3448,9 +3563,10 @@ let k = class extends E {
3448
3563
  `;
3449
3564
  }
3450
3565
  renderSignUp() {
3566
+ const e = this.legalErrorFromOAuth && this.error === this.t("errorLegalRequired");
3451
3567
  return r`
3452
3568
  <div class="stack">
3453
- ${this.renderProviders()}
3569
+ ${this.renderProviders()} ${e ? this.renderError() : n}
3454
3570
  ${(this.config?.methods?.oauth?.length ?? 0) > 0 ? r`<div class="separator-text">${this.t("or")}</div>` : n}
3455
3571
  <form class="form" @submit=${this.onSignUp} novalidate>
3456
3572
  ${this.config?.requireName !== !1 ? r`<div class="field">
@@ -3467,7 +3583,8 @@ let k = class extends E {
3467
3583
  </div>` : n}
3468
3584
  ${this.emailField()}
3469
3585
  ${this.passwordField({ label: this.t("password"), autocomplete: "new-password", id: "authui-password", field: "password", hint: this.t("passwordHint"), meter: !0 })}
3470
- ${this.renderError()} ${this.submitButton(this.t("createAccount"))}
3586
+ ${this.legalAcceptField()} ${e ? n : this.renderError()}
3587
+ ${this.submitButton(this.t("createAccount"))}
3471
3588
  </form>
3472
3589
  <div class="links">
3473
3590
  <span>${this.t("haveAccount")}</span>
@@ -3721,60 +3838,75 @@ let k = class extends E {
3721
3838
  `;
3722
3839
  }
3723
3840
  };
3724
- k.styles = [...E.styles, Wt];
3725
- C([
3726
- g({ type: String })
3727
- ], k.prototype, "view", 2);
3728
- C([
3729
- g({ type: Boolean })
3730
- ], k.prototype, "embedded", 2);
3731
- C([
3732
- d()
3733
- ], k.prototype, "step", 2);
3734
- C([
3735
- d()
3736
- ], k.prototype, "busy", 2);
3737
- C([
3738
- d()
3739
- ], k.prototype, "error", 2);
3740
- C([
3741
- d()
3742
- ], k.prototype, "notice", 2);
3743
- C([
3744
- d()
3745
- ], k.prototype, "showPassword", 2);
3746
- C([
3747
- d()
3748
- ], k.prototype, "expandedOAuth", 2);
3749
- C([
3750
- d()
3751
- ], k.prototype, "token", 2);
3752
- C([
3753
- d()
3754
- ], k.prototype, "resendCooldownUntil", 2);
3755
- C([
3756
- d()
3757
- ], k.prototype, "challenge", 2);
3758
- C([
3759
- d()
3760
- ], k.prototype, "recovery", 2);
3761
- C([
3762
- st("form input:not([type=hidden])")
3763
- ], k.prototype, "firstInput", 2);
3764
- k = C([
3841
+ $.styles = [...U.styles, Kt];
3842
+ k([
3843
+ m({ type: String })
3844
+ ], $.prototype, "view", 2);
3845
+ k([
3846
+ m({ type: Boolean })
3847
+ ], $.prototype, "embedded", 2);
3848
+ k([
3849
+ c()
3850
+ ], $.prototype, "step", 2);
3851
+ k([
3852
+ c()
3853
+ ], $.prototype, "busy", 2);
3854
+ k([
3855
+ c()
3856
+ ], $.prototype, "error", 2);
3857
+ k([
3858
+ c()
3859
+ ], $.prototype, "notice", 2);
3860
+ k([
3861
+ c()
3862
+ ], $.prototype, "showPassword", 2);
3863
+ k([
3864
+ c()
3865
+ ], $.prototype, "showPasswordConfirm", 2);
3866
+ k([
3867
+ c()
3868
+ ], $.prototype, "expandedOAuth", 2);
3869
+ k([
3870
+ c()
3871
+ ], $.prototype, "token", 2);
3872
+ k([
3873
+ c()
3874
+ ], $.prototype, "resendCooldownUntil", 2);
3875
+ k([
3876
+ c()
3877
+ ], $.prototype, "challenge", 2);
3878
+ k([
3879
+ c()
3880
+ ], $.prototype, "recovery", 2);
3881
+ k([
3882
+ at("form input:not([type=hidden])")
3883
+ ], $.prototype, "firstInput", 2);
3884
+ k([
3885
+ c()
3886
+ ], $.prototype, "password", 2);
3887
+ k([
3888
+ c()
3889
+ ], $.prototype, "passwordConfirm", 2);
3890
+ k([
3891
+ c()
3892
+ ], $.prototype, "legalAccepted", 2);
3893
+ k([
3894
+ c()
3895
+ ], $.prototype, "legalErrorFromOAuth", 2);
3896
+ $ = k([
3765
3897
  T("authui-sign-in")
3766
- ], k);
3767
- var Zt = Object.defineProperty, Xt = Object.getOwnPropertyDescriptor, m = (e, t, i, s) => {
3768
- for (var a = s > 1 ? void 0 : s ? Xt(t, i) : t, c = e.length - 1, u; c >= 0; c--)
3769
- (u = e[c]) && (a = (s ? u(t, i, a) : u(a)) || a);
3770
- return s && a && Zt(t, i, a), a;
3898
+ ], $);
3899
+ var Xt = Object.defineProperty, Qt = Object.getOwnPropertyDescriptor, f = (e, t, i, s) => {
3900
+ for (var a = s > 1 ? void 0 : s ? Qt(t, i) : t, h = e.length - 1, d; h >= 0; h--)
3901
+ (d = e[h]) && (a = (s ? d(t, i, a) : d(a)) || a);
3902
+ return s && a && Xt(t, i, a), a;
3771
3903
  };
3772
- let p = class extends E {
3904
+ let p = class extends U {
3773
3905
  constructor() {
3774
3906
  super(...arguments), this.embedded = !1, this.tab = "profile", this.active = "profile", this.busy = "", this.notice = null, this.errors = {}, this.nameInput = "", this.emailInput = "", this.emailPassword = "", this.phoneInput = "", this.phonePassword = "", this.phoneCode = "", this.phoneCodeSent = !1, this.guestName = "", this.oldPassword = "", this.newPassword = "", this.newPasswordConfirm = "", this.authenticator = null, this.authenticatorCode = "", this.factors = null, this.recoveryCodes = null, this.stepUp = null, this.stepUpCode = "", this.copied = !1, this.sessions = null, this.identities = null, this.logs = null, this.logsSupported = null, this.logsProbeStarted = !1, this.confirmDelete = !1, this.confirmRegenerate = !1, this.confirmRemoveAuthenticator = !1, this.confirmSignOutAll = !1, this.confirmDisconnectId = null, this.verifyEmailCooldownUntil = 0, this.verifyEmailCooldownTimer = null, this.onTabsKeydown = (e) => {
3775
3907
  const t = [...this.renderRoot?.querySelectorAll('[role="tab"]') ?? []];
3776
3908
  if (!t.length) return;
3777
- const i = t.findIndex((c) => c.getAttribute("aria-selected") === "true");
3909
+ const i = t.findIndex((h) => h.getAttribute("aria-selected") === "true");
3778
3910
  let s = i;
3779
3911
  if (e.key === "ArrowRight" || e.key === "ArrowDown") s = (i + 1) % t.length;
3780
3912
  else if (e.key === "ArrowLeft" || e.key === "ArrowUp")
@@ -3875,7 +4007,7 @@ let p = class extends E {
3875
4007
  try {
3876
4008
  this.recoveryCodes = await o.createRecoveryCodes();
3877
4009
  } catch (e) {
3878
- if (!q(e, f.recoveryCodesExist)) throw e;
4010
+ if (!j(e, v.recoveryCodesExist)) throw e;
3879
4011
  this.recoveryCodes = await o.getRecoveryCodes();
3880
4012
  }
3881
4013
  await this.loadFactors();
@@ -3998,9 +4130,9 @@ let p = class extends E {
3998
4130
  try {
3999
4131
  await t(), i && this.setNotice("success", i);
4000
4132
  } catch (s) {
4001
- q(s, f.challengeRequired) ? this.stepUp = { retry: () => this.run(e, t, i) } : this.errors = {
4133
+ j(s, v.challengeRequired) ? this.stepUp = { retry: () => this.run(e, t, i) } : this.errors = {
4002
4134
  ...this.errors,
4003
- [e]: K(
4135
+ [e]: Y(
4004
4136
  s,
4005
4137
  this.strings,
4006
4138
  e.includes("code") ? "code" : e === "password" ? "password" : "link"
@@ -4147,7 +4279,7 @@ let p = class extends E {
4147
4279
  return r`
4148
4280
  <div class="between">
4149
4281
  <div class="identity">
4150
- <span class="avatar">${nt(t)}</span>
4282
+ <span class="avatar">${lt(t)}</span>
4151
4283
  <div class="row-main">
4152
4284
  <span class="row-title" title=${t}>
4153
4285
  ${t}
@@ -4272,7 +4404,7 @@ let p = class extends E {
4272
4404
  autocomplete="new-password"
4273
4405
  />
4274
4406
  ${this.emailPassword ? (() => {
4275
- const t = it(this.emailPassword);
4407
+ const t = rt(this.emailPassword);
4276
4408
  return r`<div class="strength" aria-live="polite">
4277
4409
  <div
4278
4410
  class="strength-meter"
@@ -4533,7 +4665,7 @@ let p = class extends E {
4533
4665
  autocomplete="new-password"
4534
4666
  />
4535
4667
  ${this.newPassword ? (() => {
4536
- const i = it(this.newPassword);
4668
+ const i = rt(this.newPassword);
4537
4669
  return r`<div class="strength" aria-live="polite">
4538
4670
  <div
4539
4671
  class="strength-meter"
@@ -4582,7 +4714,7 @@ let p = class extends E {
4582
4714
  </div>`;
4583
4715
  }
4584
4716
  renderMfaCard() {
4585
- const e = this.user, t = this.factors?.totp ?? !1, i = this.authenticator ? o.isPreview ? Et(this.authenticator.uri) : new kt(o.getClient()).getQR(this.authenticator.uri, 400, 1).toString() : "";
4717
+ const e = this.user, t = this.factors?.totp ?? !1, i = this.authenticator ? o.isPreview ? Ut(this.authenticator.uri) : new Ct(o.getClient()).getQR(this.authenticator.uri, 400, 1).toString() : "";
4586
4718
  return this.card(
4587
4719
  this.t("twoFactor"),
4588
4720
  this.t("twoFactorDescription"),
@@ -4917,9 +5049,9 @@ let p = class extends E {
4917
5049
  ) : e.map(
4918
5050
  (i) => r`<div class="row">
4919
5051
  <div class="inline">
4920
- <span class="device">${Y(i.provider)}</span>
5052
+ <span class="device">${B(i.provider)}</span>
4921
5053
  <div class="row-main">
4922
- <span class="row-title">${W(i.provider)}</span>
5054
+ <span class="row-title">${N(i.provider)}</span>
4923
5055
  <span class="row-sub">${i.providerEmail || i.providerUid}</span>
4924
5056
  </div>
4925
5057
  </div>
@@ -4962,8 +5094,8 @@ let p = class extends E {
4962
5094
  }}
4963
5095
  ?disabled=${!!this.busy}
4964
5096
  >
4965
- ${this.spinner(`connect-${i}`)} ${Y(i)}
4966
- ${this.t("connectProvider", { provider: W(i) })}
5097
+ ${this.spinner(`connect-${i}`)} ${B(i)}
5098
+ ${this.t("connectProvider", { provider: N(i) })}
4967
5099
  </button>`
4968
5100
  )}` : void 0
4969
5101
  )}
@@ -4996,8 +5128,8 @@ let p = class extends E {
4996
5128
  }
4997
5129
  };
4998
5130
  p.styles = [
4999
- ...E.styles,
5000
- O`
5131
+ ...U.styles,
5132
+ L`
5001
5133
  :host {
5002
5134
  display: block;
5003
5135
  width: 100%;
@@ -5093,117 +5225,117 @@ p.styles = [
5093
5225
  }
5094
5226
  `
5095
5227
  ];
5096
- m([
5097
- g({ type: Boolean })
5228
+ f([
5229
+ m({ type: Boolean })
5098
5230
  ], p.prototype, "embedded", 2);
5099
- m([
5100
- g({ type: String })
5231
+ f([
5232
+ m({ type: String })
5101
5233
  ], p.prototype, "tab", 2);
5102
- m([
5103
- d()
5234
+ f([
5235
+ c()
5104
5236
  ], p.prototype, "active", 2);
5105
- m([
5106
- d()
5237
+ f([
5238
+ c()
5107
5239
  ], p.prototype, "busy", 2);
5108
- m([
5109
- d()
5240
+ f([
5241
+ c()
5110
5242
  ], p.prototype, "notice", 2);
5111
- m([
5112
- d()
5243
+ f([
5244
+ c()
5113
5245
  ], p.prototype, "errors", 2);
5114
- m([
5115
- d()
5246
+ f([
5247
+ c()
5116
5248
  ], p.prototype, "nameInput", 2);
5117
- m([
5118
- d()
5249
+ f([
5250
+ c()
5119
5251
  ], p.prototype, "emailInput", 2);
5120
- m([
5121
- d()
5252
+ f([
5253
+ c()
5122
5254
  ], p.prototype, "emailPassword", 2);
5123
- m([
5124
- d()
5255
+ f([
5256
+ c()
5125
5257
  ], p.prototype, "phoneInput", 2);
5126
- m([
5127
- d()
5258
+ f([
5259
+ c()
5128
5260
  ], p.prototype, "phonePassword", 2);
5129
- m([
5130
- d()
5261
+ f([
5262
+ c()
5131
5263
  ], p.prototype, "phoneCode", 2);
5132
- m([
5133
- d()
5264
+ f([
5265
+ c()
5134
5266
  ], p.prototype, "phoneCodeSent", 2);
5135
- m([
5136
- d()
5267
+ f([
5268
+ c()
5137
5269
  ], p.prototype, "guestName", 2);
5138
- m([
5139
- d()
5270
+ f([
5271
+ c()
5140
5272
  ], p.prototype, "oldPassword", 2);
5141
- m([
5142
- d()
5273
+ f([
5274
+ c()
5143
5275
  ], p.prototype, "newPassword", 2);
5144
- m([
5145
- d()
5276
+ f([
5277
+ c()
5146
5278
  ], p.prototype, "newPasswordConfirm", 2);
5147
- m([
5148
- d()
5279
+ f([
5280
+ c()
5149
5281
  ], p.prototype, "authenticator", 2);
5150
- m([
5151
- d()
5282
+ f([
5283
+ c()
5152
5284
  ], p.prototype, "authenticatorCode", 2);
5153
- m([
5154
- d()
5285
+ f([
5286
+ c()
5155
5287
  ], p.prototype, "factors", 2);
5156
- m([
5157
- d()
5288
+ f([
5289
+ c()
5158
5290
  ], p.prototype, "recoveryCodes", 2);
5159
- m([
5160
- d()
5291
+ f([
5292
+ c()
5161
5293
  ], p.prototype, "stepUp", 2);
5162
- m([
5163
- d()
5294
+ f([
5295
+ c()
5164
5296
  ], p.prototype, "stepUpCode", 2);
5165
- m([
5166
- d()
5297
+ f([
5298
+ c()
5167
5299
  ], p.prototype, "copied", 2);
5168
- m([
5169
- d()
5300
+ f([
5301
+ c()
5170
5302
  ], p.prototype, "sessions", 2);
5171
- m([
5172
- d()
5303
+ f([
5304
+ c()
5173
5305
  ], p.prototype, "identities", 2);
5174
- m([
5175
- d()
5306
+ f([
5307
+ c()
5176
5308
  ], p.prototype, "logs", 2);
5177
- m([
5178
- d()
5309
+ f([
5310
+ c()
5179
5311
  ], p.prototype, "logsSupported", 2);
5180
- m([
5181
- d()
5312
+ f([
5313
+ c()
5182
5314
  ], p.prototype, "confirmDelete", 2);
5183
- m([
5184
- d()
5315
+ f([
5316
+ c()
5185
5317
  ], p.prototype, "confirmRegenerate", 2);
5186
- m([
5187
- d()
5318
+ f([
5319
+ c()
5188
5320
  ], p.prototype, "confirmRemoveAuthenticator", 2);
5189
- m([
5190
- d()
5321
+ f([
5322
+ c()
5191
5323
  ], p.prototype, "confirmSignOutAll", 2);
5192
- m([
5193
- d()
5324
+ f([
5325
+ c()
5194
5326
  ], p.prototype, "confirmDisconnectId", 2);
5195
- m([
5196
- d()
5327
+ f([
5328
+ c()
5197
5329
  ], p.prototype, "verifyEmailCooldownUntil", 2);
5198
- p = m([
5330
+ p = f([
5199
5331
  T("authui-account")
5200
5332
  ], p);
5201
- var Qt = Object.defineProperty, Jt = Object.getOwnPropertyDescriptor, F = (e, t, i, s) => {
5202
- for (var a = s > 1 ? void 0 : s ? Jt(t, i) : t, c = e.length - 1, u; c >= 0; c--)
5203
- (u = e[c]) && (a = (s ? u(t, i, a) : u(a)) || a);
5204
- return s && a && Qt(t, i, a), a;
5333
+ var Jt = Object.defineProperty, te = Object.getOwnPropertyDescriptor, R = (e, t, i, s) => {
5334
+ for (var a = s > 1 ? void 0 : s ? te(t, i) : t, h = e.length - 1, d; h >= 0; h--)
5335
+ (d = e[h]) && (a = (s ? d(t, i, a) : d(a)) || a);
5336
+ return s && a && Jt(t, i, a), a;
5205
5337
  };
5206
- let P = class extends E {
5338
+ let I = class extends U {
5207
5339
  constructor() {
5208
5340
  super(...arguments), this.open = !1, this.view = "sign-in", this.closeOnSuccess = !0, this.handledPending = null, this.scrollCue = !1, this.bodyResizeObserver = null, this.onOpenEvent = (e) => {
5209
5341
  const t = e.detail ?? {};
@@ -5299,9 +5431,9 @@ let P = class extends E {
5299
5431
  `;
5300
5432
  }
5301
5433
  };
5302
- P.styles = [
5303
- ...E.styles,
5304
- O`
5434
+ I.styles = [
5435
+ ...U.styles,
5436
+ L`
5305
5437
  :host {
5306
5438
  display: contents;
5307
5439
  }
@@ -5389,14 +5521,14 @@ P.styles = [
5389
5521
  }
5390
5522
  `
5391
5523
  ];
5392
- F([
5393
- g({ type: Boolean, reflect: !0 })
5394
- ], P.prototype, "open", 2);
5395
- F([
5396
- g({ type: String })
5397
- ], P.prototype, "view", 2);
5398
- F([
5399
- g({
5524
+ R([
5525
+ m({ type: Boolean, reflect: !0 })
5526
+ ], I.prototype, "open", 2);
5527
+ R([
5528
+ m({ type: String })
5529
+ ], I.prototype, "view", 2);
5530
+ R([
5531
+ m({
5400
5532
  attribute: "close-on-success",
5401
5533
  reflect: !0,
5402
5534
  converter: {
@@ -5410,28 +5542,28 @@ F([
5410
5542
  }
5411
5543
  }
5412
5544
  })
5413
- ], P.prototype, "closeOnSuccess", 2);
5414
- F([
5415
- d()
5416
- ], P.prototype, "handledPending", 2);
5417
- F([
5418
- d()
5419
- ], P.prototype, "scrollCue", 2);
5420
- F([
5421
- st("dialog")
5422
- ], P.prototype, "dialog", 2);
5423
- F([
5424
- st(".body")
5425
- ], P.prototype, "bodyEl", 2);
5426
- P = F([
5545
+ ], I.prototype, "closeOnSuccess", 2);
5546
+ R([
5547
+ c()
5548
+ ], I.prototype, "handledPending", 2);
5549
+ R([
5550
+ c()
5551
+ ], I.prototype, "scrollCue", 2);
5552
+ R([
5553
+ at("dialog")
5554
+ ], I.prototype, "dialog", 2);
5555
+ R([
5556
+ at(".body")
5557
+ ], I.prototype, "bodyEl", 2);
5558
+ I = R([
5427
5559
  T("authui-modal")
5428
- ], P);
5429
- var te = Object.defineProperty, ee = Object.getOwnPropertyDescriptor, Q = (e, t, i, s) => {
5430
- for (var a = s > 1 ? void 0 : s ? ee(t, i) : t, c = e.length - 1, u; c >= 0; c--)
5431
- (u = e[c]) && (a = (s ? u(t, i, a) : u(a)) || a);
5432
- return s && a && te(t, i, a), a;
5560
+ ], I);
5561
+ var ee = Object.defineProperty, ie = Object.getOwnPropertyDescriptor, J = (e, t, i, s) => {
5562
+ for (var a = s > 1 ? void 0 : s ? ie(t, i) : t, h = e.length - 1, d; h >= 0; h--)
5563
+ (d = e[h]) && (a = (s ? d(t, i, a) : d(a)) || a);
5564
+ return s && a && ee(t, i, a), a;
5433
5565
  };
5434
- let L = class extends E {
5566
+ let V = class extends U {
5435
5567
  constructor() {
5436
5568
  super(...arguments), this.view = "sign-in", this.variant = "primary", this.size = "md";
5437
5569
  }
@@ -5439,7 +5571,7 @@ let L = class extends E {
5439
5571
  const e = this.size === "md" ? "" : `btn-${this.size}`;
5440
5572
  return r`<button
5441
5573
  class="btn btn-${this.variant} ${e}"
5442
- @click=${() => Z(this.view)}
5574
+ @click=${() => X(this.view)}
5443
5575
  part="button"
5444
5576
  >
5445
5577
  <slot
@@ -5448,9 +5580,9 @@ let L = class extends E {
5448
5580
  </button>`;
5449
5581
  }
5450
5582
  };
5451
- L.styles = [
5452
- ...E.styles,
5453
- O`
5583
+ V.styles = [
5584
+ ...U.styles,
5585
+ L`
5454
5586
  :host {
5455
5587
  display: inline-block;
5456
5588
  }
@@ -5459,26 +5591,26 @@ L.styles = [
5459
5591
  }
5460
5592
  `
5461
5593
  ];
5462
- Q([
5463
- g({ type: String })
5464
- ], L.prototype, "view", 2);
5465
- Q([
5466
- g({ type: String })
5467
- ], L.prototype, "variant", 2);
5468
- Q([
5469
- g({ type: String })
5470
- ], L.prototype, "size", 2);
5471
- L = Q([
5594
+ J([
5595
+ m({ type: String })
5596
+ ], V.prototype, "view", 2);
5597
+ J([
5598
+ m({ type: String })
5599
+ ], V.prototype, "variant", 2);
5600
+ J([
5601
+ m({ type: String })
5602
+ ], V.prototype, "size", 2);
5603
+ V = J([
5472
5604
  T("authui-button")
5473
- ], L);
5474
- var ie = Object.defineProperty, se = Object.getOwnPropertyDescriptor, R = (e, t, i, s) => {
5475
- for (var a = s > 1 ? void 0 : s ? se(t, i) : t, c = e.length - 1, u; c >= 0; c--)
5476
- (u = e[c]) && (a = (s ? u(t, i, a) : u(a)) || a);
5477
- return s && a && ie(t, i, a), a;
5605
+ ], V);
5606
+ var se = Object.defineProperty, re = Object.getOwnPropertyDescriptor, F = (e, t, i, s) => {
5607
+ for (var a = s > 1 ? void 0 : s ? re(t, i) : t, h = e.length - 1, d; h >= 0; h--)
5608
+ (d = e[h]) && (a = (s ? d(t, i, a) : d(a)) || a);
5609
+ return s && a && se(t, i, a), a;
5478
5610
  };
5479
- let I = class extends E {
5611
+ let E = class extends U {
5480
5612
  constructor() {
5481
- super(...arguments), this.showTeams = !1, this.src = "", this.menuOpen = !1, this.menuAbove = !1, this.teams = [], this.teamsLoading = !1, this.activeTeamId = null, this.onReposition = () => {
5613
+ super(...arguments), this.showTeams = !1, this.menuItems = [], this.src = "", this.menuOpen = !1, this.menuAbove = !1, this.teams = [], this.teamsLoading = !1, this.activeTeamId = null, this.onReposition = () => {
5482
5614
  this.menuOpen && this.placeMenu();
5483
5615
  }, this.onDocumentClick = (e) => {
5484
5616
  e.composedPath().includes(this) || (this.menuOpen = !1);
@@ -5521,10 +5653,10 @@ let I = class extends E {
5521
5653
  if (!e || !t) return;
5522
5654
  const i = e.getBoundingClientRect(), s = 6, a = 8;
5523
5655
  t.style.maxHeight = "";
5524
- const c = t.offsetHeight + s, u = window.innerHeight - i.bottom, b = i.top, $ = u < c && b > u;
5525
- $ !== this.menuAbove && (this.menuAbove = $);
5526
- const ot = Math.max(80, ($ ? b : u) - s - a);
5527
- t.style.maxHeight = `${ot}px`;
5656
+ const h = t.offsetHeight + s, d = window.innerHeight - i.bottom, g = i.top, y = d < h && g > d;
5657
+ y !== this.menuAbove && (this.menuAbove = y);
5658
+ const C = Math.max(80, (y ? g : d) - s - a);
5659
+ t.style.maxHeight = `${C}px`;
5528
5660
  }
5529
5661
  focusMenuItem(e) {
5530
5662
  [
@@ -5551,7 +5683,7 @@ let I = class extends E {
5551
5683
  if (e === "loading" && i)
5552
5684
  return r`<span class="avatar"><span class="spinner"></span></span>`;
5553
5685
  if (e !== "signed-in" || !t)
5554
- return r`<button class="btn btn-primary btn-sm" @click=${() => Z("sign-in")}>
5686
+ return r`<button class="btn btn-primary btn-sm" @click=${() => X("sign-in")}>
5555
5687
  <slot>${this.t("signIn")}</slot>
5556
5688
  </button>`;
5557
5689
  const s = t.name || t.email || t.phone || this.t("guestAccount");
@@ -5564,7 +5696,7 @@ let I = class extends E {
5564
5696
  aria-label=${s}
5565
5697
  >
5566
5698
  <span class="avatar"
5567
- >${this.src ? r`<img src=${this.src} alt="" />` : nt(s)}</span
5699
+ >${this.src ? r`<img src=${this.src} alt="" />` : lt(s)}</span
5568
5700
  >
5569
5701
  </button>
5570
5702
  ${this.menuOpen ? r`<div class="menu ${this.menuAbove ? "above" : ""}" role="menu">
@@ -5589,11 +5721,13 @@ let I = class extends E {
5589
5721
  </button>`
5590
5722
  )}
5591
5723
  </div>` : n}
5724
+ ${this.renderCustomMenuItems()}
5725
+ <slot name="menu-items"></slot>
5592
5726
  <button
5593
5727
  class="menu-item"
5594
5728
  role="menuitem"
5595
5729
  @click=${() => {
5596
- this.menuOpen = !1, Z("account");
5730
+ this.menuOpen = !1, X("account");
5597
5731
  }}
5598
5732
  >
5599
5733
  ${l.settings} ${this.t("manageAccount")}
@@ -5610,10 +5744,46 @@ let I = class extends E {
5610
5744
  </div>` : n}
5611
5745
  `;
5612
5746
  }
5747
+ renderCustomMenuItems() {
5748
+ return this.menuItems?.length ? this.menuItems.map((e) => {
5749
+ if (e.href) {
5750
+ const i = e.target;
5751
+ return r`<a
5752
+ class="menu-item"
5753
+ role="menuitem"
5754
+ href=${e.href}
5755
+ target=${i || n}
5756
+ rel=${i === "_blank" ? "noopener noreferrer" : n}
5757
+ @click=${() => {
5758
+ this.menuOpen = !1;
5759
+ }}
5760
+ >
5761
+ ${e.label}
5762
+ </a>`;
5763
+ }
5764
+ const t = e.actionId;
5765
+ return r`<button
5766
+ class="menu-item"
5767
+ role="menuitem"
5768
+ type="button"
5769
+ @click=${() => {
5770
+ this.menuOpen = !1, t && this.dispatchEvent(
5771
+ new CustomEvent("authui-menu-action", {
5772
+ detail: { actionId: t },
5773
+ bubbles: !0,
5774
+ composed: !0
5775
+ })
5776
+ );
5777
+ }}
5778
+ >
5779
+ ${e.label}
5780
+ </button>`;
5781
+ }) : n;
5782
+ }
5613
5783
  };
5614
- I.styles = [
5615
- ...E.styles,
5616
- O`
5784
+ E.styles = [
5785
+ ...U.styles,
5786
+ L`
5617
5787
  :host {
5618
5788
  display: inline-block;
5619
5789
  position: relative;
@@ -5702,6 +5872,10 @@ I.styles = [
5702
5872
  height: 16px;
5703
5873
  color: var(--authui-muted-foreground);
5704
5874
  }
5875
+ a.menu-item {
5876
+ text-decoration: none;
5877
+ box-sizing: border-box;
5878
+ }
5705
5879
  .menu-section {
5706
5880
  border-top: 1px solid var(--authui-border);
5707
5881
  margin-top: 4px;
@@ -5729,60 +5903,63 @@ I.styles = [
5729
5903
  }
5730
5904
  `
5731
5905
  ];
5732
- R([
5733
- g({ type: Boolean, attribute: "show-teams" })
5734
- ], I.prototype, "showTeams", 2);
5735
- R([
5736
- g({ type: String })
5737
- ], I.prototype, "src", 2);
5738
- R([
5739
- d()
5740
- ], I.prototype, "menuOpen", 2);
5741
- R([
5742
- d()
5743
- ], I.prototype, "menuAbove", 2);
5744
- R([
5745
- d()
5746
- ], I.prototype, "teams", 2);
5747
- R([
5748
- d()
5749
- ], I.prototype, "teamsLoading", 2);
5750
- R([
5751
- d()
5752
- ], I.prototype, "activeTeamId", 2);
5753
- I = R([
5906
+ F([
5907
+ m({ type: Boolean, attribute: "show-teams" })
5908
+ ], E.prototype, "showTeams", 2);
5909
+ F([
5910
+ m({ attribute: !1 })
5911
+ ], E.prototype, "menuItems", 2);
5912
+ F([
5913
+ m({ type: String })
5914
+ ], E.prototype, "src", 2);
5915
+ F([
5916
+ c()
5917
+ ], E.prototype, "menuOpen", 2);
5918
+ F([
5919
+ c()
5920
+ ], E.prototype, "menuAbove", 2);
5921
+ F([
5922
+ c()
5923
+ ], E.prototype, "teams", 2);
5924
+ F([
5925
+ c()
5926
+ ], E.prototype, "teamsLoading", 2);
5927
+ F([
5928
+ c()
5929
+ ], E.prototype, "activeTeamId", 2);
5930
+ E = F([
5754
5931
  T("authui-user-button")
5755
- ], I);
5932
+ ], E);
5756
5933
  export {
5757
- Ft as A,
5758
- le as C,
5759
- f as E,
5760
- bt as F,
5934
+ Lt as A,
5935
+ ce as C,
5936
+ v as E,
5937
+ yt as F,
5761
5938
  It as P,
5762
5939
  o as a,
5763
5940
  p as b,
5764
- ce as c,
5765
- L as d,
5766
- y as e,
5767
- E as f,
5768
- P as g,
5769
- N as h,
5770
- k as i,
5771
- I as j,
5772
- oe as k,
5773
- pt as l,
5774
- Ct as m,
5775
- K as n,
5776
- Z as o,
5941
+ de as c,
5942
+ V as d,
5943
+ w as e,
5944
+ U as f,
5945
+ I as g,
5946
+ H as h,
5947
+ $ as i,
5948
+ E as j,
5949
+ le as k,
5950
+ mt as l,
5951
+ St as m,
5952
+ Y as n,
5953
+ X as o,
5777
5954
  z as p,
5778
- ut as q,
5779
- Ut as r,
5780
- W as s,
5781
- V as t,
5782
- wt as u,
5783
- it as v,
5784
- Mt as w,
5785
- Ot as x,
5786
- _ as y,
5787
- jt as z
5955
+ pt as q,
5956
+ Mt as r,
5957
+ N as s,
5958
+ _ as t,
5959
+ $t as u,
5960
+ rt as v,
5961
+ Ot as w,
5962
+ Ft as x,
5963
+ q as y,
5964
+ Wt as z
5788
5965
  };