@burdenoff/microfe-auth 2026.527.1 → 2026.527.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (61) hide show
  1. package/dist/auth/AuthRoutes.js +1 -1
  2. package/dist/auth/AuthRoutes.js.map +1 -1
  3. package/dist/auth/components/AuthLayout.js +14 -14
  4. package/dist/auth/components/AuthLayout.js.map +1 -1
  5. package/dist/auth/components/CaptchaV2.js +1 -4
  6. package/dist/auth/components/CaptchaV2.js.map +1 -1
  7. package/dist/auth/components/ConfirmActionDialog.js +3 -3
  8. package/dist/auth/components/ConfirmActionDialog.js.map +1 -1
  9. package/dist/auth/components/profile/UserProfileMenu.js +10 -6
  10. package/dist/auth/components/profile/UserProfileMenu.js.map +1 -1
  11. package/dist/auth/components/workspace/WorkspaceSelector.js +5 -5
  12. package/dist/auth/components/workspace/WorkspaceSelector.js.map +1 -1
  13. package/dist/auth/hooks/index.js +2 -2
  14. package/dist/auth/index.js +4 -4
  15. package/dist/auth/pages/AuditLogPage.js +7 -7
  16. package/dist/auth/pages/AuditLogPage.js.map +1 -1
  17. package/dist/auth/pages/EmailVerifyPage.js +10 -8
  18. package/dist/auth/pages/EmailVerifyPage.js.map +1 -1
  19. package/dist/auth/pages/LoginPage.js +20 -19
  20. package/dist/auth/pages/LoginPage.js.map +1 -1
  21. package/dist/auth/pages/MagicLinkPage.js +10 -8
  22. package/dist/auth/pages/MagicLinkPage.js.map +1 -1
  23. package/dist/auth/pages/MfaSetupPage.js +26 -21
  24. package/dist/auth/pages/MfaSetupPage.js.map +1 -1
  25. package/dist/auth/pages/MfaVerifyPage.js +21 -21
  26. package/dist/auth/pages/MfaVerifyPage.js.map +1 -1
  27. package/dist/auth/pages/OAuthCallbackPage.js +7 -6
  28. package/dist/auth/pages/OAuthCallbackPage.js.map +1 -1
  29. package/dist/auth/pages/PasswordResetPage.js +25 -22
  30. package/dist/auth/pages/PasswordResetPage.js.map +1 -1
  31. package/dist/auth/pages/ReactivatePage.js +17 -15
  32. package/dist/auth/pages/ReactivatePage.js.map +1 -1
  33. package/dist/auth/pages/RegisterPage.js +198 -194
  34. package/dist/auth/pages/RegisterPage.js.map +1 -1
  35. package/dist/auth/pages/SSOClearPage.js +1 -1
  36. package/dist/auth/pages/SSOClearPage.js.map +1 -1
  37. package/dist/auth/pages/SSODepositPage.js +1 -1
  38. package/dist/auth/pages/SSODepositPage.js.map +1 -1
  39. package/dist/auth/pages/SSORelayCallbackPage.js +1 -1
  40. package/dist/auth/pages/SSORelayCallbackPage.js.map +1 -1
  41. package/dist/auth/pages/SSORelayPage.js +1 -1
  42. package/dist/auth/pages/SSORelayPage.js.map +1 -1
  43. package/dist/auth/pages/SecurityPage.js +15 -16
  44. package/dist/auth/pages/SecurityPage.js.map +1 -1
  45. package/dist/auth/pages/SessionsPage.js +19 -20
  46. package/dist/auth/pages/SessionsPage.js.map +1 -1
  47. package/dist/auth/pages/SsoCallbackPage.js +19 -15
  48. package/dist/auth/pages/SsoCallbackPage.js.map +1 -1
  49. package/dist/auth/pages/SsoConfigPage.js +41 -27
  50. package/dist/auth/pages/SsoConfigPage.js.map +1 -1
  51. package/dist/auth/pages/SsoLoginPage.js +16 -14
  52. package/dist/auth/pages/SsoLoginPage.js.map +1 -1
  53. package/dist/auth/pages/UserDetailsPage.js +16 -17
  54. package/dist/auth/pages/UserDetailsPage.js.map +1 -1
  55. package/dist/auth/pages/UserProfilePage.js +31 -25
  56. package/dist/auth/pages/UserProfilePage.js.map +1 -1
  57. package/dist/auth/pages/UsersPage.js +46 -42
  58. package/dist/auth/pages/UsersPage.js.map +1 -1
  59. package/dist/index.js +11 -11
  60. package/dist/microfe-auth.css +1 -1
  61. package/package.json +1 -1
@@ -1,137 +1,138 @@
1
1
  import { useAuth as e } from "../providers/AuthProvider.js";
2
- import { useAuthOperations as t } from "../hooks/useAuthOperations.js";
3
- import { useOAuthOperations as n } from "../hooks/useOAuthOperations.js";
4
- import { AuthLayout as r } from "../components/AuthLayout.js";
5
- import { AlertIcon as i, CheckIcon as a, EmailIcon as o, EyeIcon as s, EyeOffIcon as c, GitHubIcon as l, GoogleIcon as u, LockIcon as d, MicrosoftIcon as f, SpinnerIcon as p, UserIcon as m, XIcon as ee } from "../components/AuthIcons.js";
6
- import { validateEmail as te, validatePassword as h } from "../utils/validation.js";
7
- import { CaptchaV2 as ne, isCaptchaEnabled as g } from "../components/CaptchaV2.js";
8
- import { useState as _ } from "react";
9
- import { useNavigate as v } from "react-router-dom";
10
- import { useI18n as y } from "@burdenoff/fe-libs/shared/providers/shell";
11
- import { Fragment as b, jsx as x, jsxs as S } from "react/jsx-runtime";
2
+ import { isCaptchaEnabled as t } from "../utils/captchaConfig.js";
3
+ import { useAuthOperations as n } from "../hooks/useAuthOperations.js";
4
+ import { useOAuthOperations as r } from "../hooks/useOAuthOperations.js";
5
+ import { AuthLayout as i } from "../components/AuthLayout.js";
6
+ import { AlertIcon as a, CheckIcon as o, EmailIcon as s, EyeIcon as c, EyeOffIcon as l, GitHubIcon as u, GoogleIcon as d, LockIcon as f, MicrosoftIcon as p, SpinnerIcon as m, UserIcon as h, XIcon as ee } from "../components/AuthIcons.js";
7
+ import { validateEmail as g, validatePassword as te } from "../utils/validation.js";
8
+ import { CaptchaV2 as _ } from "../components/CaptchaV2.js";
9
+ import { useState as v } from "react";
10
+ import { useNavigate as y } from "react-router-dom";
11
+ import { useI18n as b } from "@burdenoff/fe-libs/shared/providers/shell";
12
+ import { Fragment as x, jsx as S, jsxs as C } from "react/jsx-runtime";
12
13
  //#region src/auth/pages/RegisterPage.tsx
13
- function C() {
14
- let { productName: C } = e(), w = v(), { t: T } = y(), E = (e, t) => {
15
- let n = T(e);
14
+ function w() {
15
+ let { productName: w } = e(), T = y(), { t: E } = b(), D = (e, t) => {
16
+ let n = E(e);
16
17
  return n === e ? t : n;
17
- }, { signUp: re, resendVerification: ie, isLoading: D } = t(), { initiateGoogleOAuth: O, initiateMicrosoftOAuth: k, isProviderConfigured: A } = n(), [j, M] = _(!1), [N, P] = _({
18
+ }, { signUp: ne, resendVerification: re, isLoading: O } = n(), { initiateGoogleOAuth: k, initiateMicrosoftOAuth: A, isProviderConfigured: j } = r(), [M, N] = v(!1), [P, F] = v({
18
19
  email: "",
19
20
  username: "",
20
21
  password: "",
21
22
  firstName: "",
22
23
  lastName: ""
23
- }), [F, I] = _([]), [L, R] = _(!1), [z, B] = _(null), [V, H] = _(null), [U, W] = _(null), [G, K] = _(!1), [q, J] = _(null), Y = (() => {
24
- let e = N.password;
24
+ }), [I, L] = v([]), [R, z] = v(!1), [B, V] = v(null), [H, U] = v(null), [W, G] = v(null), [K, q] = v(!1), [J, Y] = v(null), X = (() => {
25
+ let e = P.password;
25
26
  return [
26
27
  {
27
- label: E("auth.register.pwMin8", "At least 12 characters"),
28
+ label: D("auth.register.pwMin8", "At least 12 characters"),
28
29
  met: e.length >= 12
29
30
  },
30
31
  {
31
- label: E("auth.register.pwUppercase", "One uppercase letter"),
32
+ label: D("auth.register.pwUppercase", "One uppercase letter"),
32
33
  met: /[A-Z]/.test(e)
33
34
  },
34
35
  {
35
- label: E("auth.register.pwLowercase", "One lowercase letter"),
36
+ label: D("auth.register.pwLowercase", "One lowercase letter"),
36
37
  met: /[a-z]/.test(e)
37
38
  },
38
39
  {
39
- label: E("auth.register.pwNumber", "One number"),
40
+ label: D("auth.register.pwNumber", "One number"),
40
41
  met: /\d/.test(e)
41
42
  },
42
43
  {
43
- label: E("auth.register.pwSpecial", "One special character"),
44
+ label: D("auth.register.pwSpecial", "One special character"),
44
45
  met: /[!@#$%^&*(),.?":{}|<>]/.test(e)
45
46
  }
46
47
  ];
47
- })(), X = (() => {
48
- let e = Y.filter((e) => e.met).length;
48
+ })(), Z = (() => {
49
+ let e = X.filter((e) => e.met).length;
49
50
  return e <= 2 ? {
50
- level: E("auth.register.passwordStrengthWeak", "weak"),
51
+ level: D("auth.register.passwordStrengthWeak", "weak"),
51
52
  color: "bg-status-error-bg-subtle0",
52
53
  width: "w-1/4"
53
54
  } : e <= 3 ? {
54
- level: E("auth.register.passwordStrengthFair", "fair"),
55
+ level: D("auth.register.passwordStrengthFair", "fair"),
55
56
  color: "bg-status-warning-text",
56
57
  width: "w-2/4"
57
58
  } : e <= 4 ? {
58
- level: E("auth.register.passwordStrengthGood", "good"),
59
+ level: D("auth.register.passwordStrengthGood", "good"),
59
60
  color: "bg-status-warning-bg-subtle0",
60
61
  width: "w-3/4"
61
62
  } : {
62
- level: E("auth.register.passwordStrengthStrong", "strong"),
63
+ level: D("auth.register.passwordStrengthStrong", "strong"),
63
64
  color: "bg-status-success-text",
64
65
  width: "w-full"
65
66
  };
66
- })(), ae = async (e) => {
67
+ })(), ie = async (e) => {
67
68
  e.preventDefault();
68
- let t = [];
69
- te(N.email) || t.push(E("auth.register.invalidEmail", "Please enter a valid email address")), (!N.username || N.username.length < 3) && t.push(E("auth.register.usernameMin3", "Username must be at least 3 characters")), /^[a-zA-Z0-9_-]+$/.test(N.username) || t.push(E("auth.register.usernameChars", "Username can only contain letters, numbers, underscores, and hyphens"));
70
- let n = h(N.password);
71
- if (n.valid || t.push(...n.errors), g() && !U && t.push(E("auth.register.completeCaptcha", "Please complete the reCAPTCHA verification")), t.length > 0) {
72
- I(t);
69
+ let n = [];
70
+ g(P.email) || n.push(D("auth.register.invalidEmail", "Please enter a valid email address")), (!P.username || P.username.length < 3) && n.push(D("auth.register.usernameMin3", "Username must be at least 3 characters")), /^[a-zA-Z0-9_-]+$/.test(P.username) || n.push(D("auth.register.usernameChars", "Username can only contain letters, numbers, underscores, and hyphens"));
71
+ let r = te(P.password);
72
+ if (r.valid || n.push(...r.errors), t() && !W && n.push(D("auth.register.completeCaptcha", "Please complete the reCAPTCHA verification")), n.length > 0) {
73
+ L(n);
73
74
  return;
74
75
  }
75
- I([]), B(null);
76
+ L([]), V(null);
76
77
  try {
77
- await re({
78
- ...N,
79
- ...U ? { recaptchaToken: U } : {}
80
- }), R(!0);
78
+ await ne({
79
+ ...P,
80
+ ...W ? { recaptchaToken: W } : {}
81
+ }), z(!0);
81
82
  } catch (e) {
82
- B(e instanceof Error ? e.message : E("auth.register.signUpFailed", "Sign up failed")), console.error("Sign up failed:", e);
83
+ V(e instanceof Error ? e.message : D("auth.register.signUpFailed", "Sign up failed")), console.error("Sign up failed:", e);
83
84
  }
84
- }, oe = () => {
85
- H(null);
85
+ }, ae = () => {
86
+ U(null);
86
87
  try {
87
- O();
88
+ k();
88
89
  } catch (e) {
89
- H(e instanceof Error ? e.message : E("auth.register.googleSignUpFailed", "Failed to initiate Google sign up"));
90
+ U(e instanceof Error ? e.message : D("auth.register.googleSignUpFailed", "Failed to initiate Google sign up"));
90
91
  }
91
- }, Z = () => {
92
- H(null);
92
+ }, oe = () => {
93
+ U(null);
93
94
  try {
94
- k();
95
+ A();
95
96
  } catch (e) {
96
- H(e instanceof Error ? e.message : E("auth.register.microsoftSignUpFailed", "Failed to initiate Microsoft sign up"));
97
+ U(e instanceof Error ? e.message : D("auth.register.microsoftSignUpFailed", "Failed to initiate Microsoft sign up"));
97
98
  }
98
- }, Q = A("google"), $ = A("microsoft"), se = [
99
+ }, Q = j("google"), $ = j("microsoft"), se = [
99
100
  {
100
101
  name: "Google",
101
- icon: u,
102
- onClick: oe,
102
+ icon: d,
103
+ onClick: ae,
103
104
  disabled: !Q,
104
- tooltip: Q ? void 0 : E("auth.register.googleNotConfigured", "Google sign up is not configured")
105
+ tooltip: Q ? void 0 : D("auth.register.googleNotConfigured", "Google sign up is not configured")
105
106
  },
106
107
  {
107
108
  name: "GitHub",
108
- icon: l,
109
+ icon: u,
109
110
  onClick: () => {},
110
111
  disabled: !0,
111
- tooltip: E("auth.register.githubNotConfigured", "GitHub sign up is not configured")
112
+ tooltip: D("auth.register.githubNotConfigured", "GitHub sign up is not configured")
112
113
  },
113
114
  {
114
115
  name: "Microsoft",
115
- icon: f,
116
- onClick: Z,
116
+ icon: p,
117
+ onClick: oe,
117
118
  disabled: !$,
118
- tooltip: $ ? void 0 : E("auth.register.microsoftNotConfigured", "Microsoft sign up is not configured")
119
+ tooltip: $ ? void 0 : D("auth.register.microsoftNotConfigured", "Microsoft sign up is not configured")
119
120
  }
120
- ], [ce, le = ""] = E("auth.register.verificationEmailSentTo", "We've sent a verification email to {{email}}. Please check your inbox and click the verification link to activate your account.").split("{{email}}");
121
- return L ? /* @__PURE__ */ x(r, {
122
- title: E("auth.register.checkEmail", "Check your email"),
123
- subtitle: E("auth.register.verificationLinkSent", "We've sent you a verification link"),
124
- children: /* @__PURE__ */ S("div", {
121
+ ], [ce, le = ""] = D("auth.register.verificationEmailSentTo", "We've sent a verification email to {{email}}. Please check your inbox and click the verification link to activate your account.").split("{{email}}");
122
+ return R ? /* @__PURE__ */ S(i, {
123
+ title: D("auth.register.checkEmail", "Check your email"),
124
+ subtitle: D("auth.register.verificationLinkSent", "We've sent you a verification link"),
125
+ children: /* @__PURE__ */ C("div", {
125
126
  className: "flex flex-col items-center justify-center py-6",
126
127
  children: [
127
- /* @__PURE__ */ x("div", {
128
- className: "w-20 h-20 rounded-full bg-status-success-bg-subtle flex items-center justify-center mb-6",
129
- children: /* @__PURE__ */ x("svg", {
130
- className: "w-10 h-10 text-status-success-text",
128
+ /* @__PURE__ */ S("div", {
129
+ className: "size-20 rounded-full bg-status-success-bg-subtle flex items-center justify-center mb-6",
130
+ children: /* @__PURE__ */ S("svg", {
131
+ className: "size-10 text-status-success-text",
131
132
  fill: "none",
132
133
  viewBox: "0 0 24 24",
133
134
  stroke: "currentColor",
134
- children: /* @__PURE__ */ x("path", {
135
+ children: /* @__PURE__ */ S("path", {
135
136
  strokeLinecap: "round",
136
137
  strokeLinejoin: "round",
137
138
  strokeWidth: 2,
@@ -139,52 +140,54 @@ function C() {
139
140
  })
140
141
  })
141
142
  }),
142
- /* @__PURE__ */ x("h3", {
143
+ /* @__PURE__ */ S("h3", {
143
144
  className: "text-lg font-semibold text-[var(--color-text-primary)] mb-2",
144
- children: E("auth.register.accountCreated", "Account created successfully!")
145
+ children: D("auth.register.accountCreated", "Account created successfully!")
145
146
  }),
146
- /* @__PURE__ */ S("p", {
147
+ /* @__PURE__ */ C("p", {
147
148
  className: "text-center text-[var(--color-text-secondary)] mb-8 max-w-sm",
148
149
  children: [
149
150
  ce,
150
- /* @__PURE__ */ x("span", {
151
+ /* @__PURE__ */ S("span", {
151
152
  className: "font-medium text-[var(--color-text-primary)]",
152
- children: N.email
153
+ children: P.email
153
154
  }),
154
155
  le
155
156
  ]
156
157
  }),
157
- /* @__PURE__ */ S("div", {
158
+ /* @__PURE__ */ C("div", {
158
159
  className: "space-y-3 w-full",
159
160
  children: [
160
- /* @__PURE__ */ x("button", {
161
- onClick: () => w("/auth/login"),
161
+ /* @__PURE__ */ S("button", {
162
+ type: "button",
163
+ onClick: () => T("/auth/login"),
162
164
  className: "auth-primary-button w-full px-4 py-3 font-semibold",
163
- children: E("auth.register.continueToSignIn", "Continue to sign in")
165
+ children: D("auth.register.continueToSignIn", "Continue to sign in")
164
166
  }),
165
- q && /* @__PURE__ */ x("p", {
167
+ J && /* @__PURE__ */ S("p", {
166
168
  className: "text-center text-sm text-status-error-text",
167
- children: q
169
+ children: J
168
170
  }),
169
- /* @__PURE__ */ S("p", {
171
+ /* @__PURE__ */ C("p", {
170
172
  className: "text-center text-sm text-[var(--color-text-tertiary)]",
171
173
  children: [
172
- E("auth.register.didntReceiveEmail", "Didn't receive the email? Check your spam folder or"),
174
+ D("auth.register.didntReceiveEmail", "Didn't receive the email? Check your spam folder or"),
173
175
  " ",
174
- /* @__PURE__ */ x("button", {
175
- disabled: G,
176
+ /* @__PURE__ */ S("button", {
177
+ type: "button",
178
+ disabled: K,
176
179
  onClick: async () => {
177
- J(null), K(!0);
180
+ Y(null), q(!0);
178
181
  try {
179
- await ie(N.email);
182
+ await re(P.email);
180
183
  } catch (e) {
181
- J(e instanceof Error ? e.message : E("auth.register.resendFailed", "Failed to resend verification email"));
184
+ Y(e instanceof Error ? e.message : D("auth.register.resendFailed", "Failed to resend verification email"));
182
185
  } finally {
183
- K(!1);
186
+ q(!1);
184
187
  }
185
188
  },
186
189
  className: "text-text-link hover:text-text-linkHover font-medium disabled:opacity-50 disabled:cursor-not-allowed",
187
- children: G ? E("auth.register.resending", "resending...") : E("auth.register.tryAgain", "try again")
190
+ children: K ? D("auth.register.resending", "resending...") : D("auth.register.tryAgain", "try again")
188
191
  })
189
192
  ]
190
193
  })
@@ -192,266 +195,267 @@ function C() {
192
195
  })
193
196
  ]
194
197
  })
195
- }) : /* @__PURE__ */ S(r, {
196
- title: E("auth.register.createAccount", "Create your account"),
197
- subtitle: E("auth.register.startJourney", "Start your journey with {{productName}}").replace("{{productName}}", C || "Burdenoff Workspaces"),
198
- productName: C,
198
+ }) : /* @__PURE__ */ C(i, {
199
+ title: D("auth.register.createAccount", "Create your account"),
200
+ subtitle: D("auth.register.startJourney", "Start your journey with {{productName}}").replace("{{productName}}", w || "Burdenoff Workspaces"),
201
+ productName: w,
199
202
  children: [
200
- /* @__PURE__ */ S("form", {
201
- onSubmit: ae,
203
+ /* @__PURE__ */ C("form", {
204
+ onSubmit: ie,
202
205
  className: "space-y-5",
203
206
  children: [
204
- (z || F.length > 0) && /* @__PURE__ */ S("div", {
207
+ (B || I.length > 0) && /* @__PURE__ */ C("div", {
205
208
  className: "flex items-start gap-3 p-4 rounded-xl bg-status-error-bg-subtle border border-status-error-border",
206
- children: [/* @__PURE__ */ x(i, { className: "w-5 h-5 text-status-error-text flex-shrink-0 mt-0.5" }), /* @__PURE__ */ S("div", {
209
+ children: [/* @__PURE__ */ S(a, { className: "size-5 text-status-error-text flex-shrink-0 mt-0.5" }), /* @__PURE__ */ C("div", {
207
210
  className: "space-y-1",
208
- children: [z && /* @__PURE__ */ x("p", {
211
+ children: [B && /* @__PURE__ */ S("p", {
209
212
  className: "text-sm text-status-error-text",
210
- children: z
211
- }), F.map((e, t) => /* @__PURE__ */ x("p", {
213
+ children: B
214
+ }), I.map((e) => /* @__PURE__ */ S("p", {
212
215
  className: "text-sm text-status-error-text",
213
216
  children: e
214
- }, t))]
217
+ }, e))]
215
218
  })]
216
219
  }),
217
- /* @__PURE__ */ S("div", {
220
+ /* @__PURE__ */ C("div", {
218
221
  className: "grid grid-cols-2 gap-4",
219
- children: [/* @__PURE__ */ S("div", {
222
+ children: [/* @__PURE__ */ C("div", {
220
223
  className: "space-y-2",
221
- children: [/* @__PURE__ */ x("label", {
224
+ children: [/* @__PURE__ */ S("label", {
222
225
  htmlFor: "firstName",
223
226
  className: "block text-sm font-medium text-[var(--color-text-primary)]",
224
- children: E("auth.register.firstName", "First Name")
225
- }), /* @__PURE__ */ x("input", {
227
+ children: D("auth.register.firstName", "First Name")
228
+ }), /* @__PURE__ */ S("input", {
226
229
  id: "firstName",
227
230
  type: "text",
228
231
  required: !0,
229
232
  "aria-required": "true",
230
- value: N.firstName,
231
- onChange: (e) => P({
232
- ...N,
233
+ value: P.firstName,
234
+ onChange: (e) => F({
235
+ ...P,
233
236
  firstName: e.target.value
234
237
  }),
235
238
  className: "block w-full px-4 py-3 rounded-xl border border-[var(--color-border-default)] bg-[var(--color-bg-surface)] text-[var(--color-text-primary)] placeholder:text-[var(--color-text-tertiary)] focus:outline-none focus:ring-2 focus:ring-action-primary-bg/20 focus:border-action-primary-bg transition-all",
236
- placeholder: E("auth.register.firstNamePlaceholder", "Enter first name")
239
+ placeholder: D("auth.register.firstNamePlaceholder", "Enter first name")
237
240
  })]
238
- }), /* @__PURE__ */ S("div", {
241
+ }), /* @__PURE__ */ C("div", {
239
242
  className: "space-y-2",
240
- children: [/* @__PURE__ */ x("label", {
243
+ children: [/* @__PURE__ */ S("label", {
241
244
  htmlFor: "lastName",
242
245
  className: "block text-sm font-medium text-[var(--color-text-primary)]",
243
- children: E("auth.register.lastName", "Last Name")
244
- }), /* @__PURE__ */ x("input", {
246
+ children: D("auth.register.lastName", "Last Name")
247
+ }), /* @__PURE__ */ S("input", {
245
248
  id: "lastName",
246
249
  type: "text",
247
250
  required: !0,
248
251
  "aria-required": "true",
249
- value: N.lastName,
250
- onChange: (e) => P({
251
- ...N,
252
+ value: P.lastName,
253
+ onChange: (e) => F({
254
+ ...P,
252
255
  lastName: e.target.value
253
256
  }),
254
257
  className: "block w-full px-4 py-3 rounded-xl border border-[var(--color-border-default)] bg-[var(--color-bg-surface)] text-[var(--color-text-primary)] placeholder:text-[var(--color-text-tertiary)] focus:outline-none focus:ring-2 focus:ring-action-primary-bg/20 focus:border-action-primary-bg transition-all",
255
- placeholder: E("auth.register.lastNamePlaceholder", "Enter last name")
258
+ placeholder: D("auth.register.lastNamePlaceholder", "Enter last name")
256
259
  })]
257
260
  })]
258
261
  }),
259
- /* @__PURE__ */ S("div", {
262
+ /* @__PURE__ */ C("div", {
260
263
  className: "space-y-2",
261
- children: [/* @__PURE__ */ x("label", {
264
+ children: [/* @__PURE__ */ S("label", {
262
265
  htmlFor: "username",
263
266
  className: "block text-sm font-medium text-[var(--color-text-primary)]",
264
- children: E("auth.register.username", "Username")
265
- }), /* @__PURE__ */ S("div", {
267
+ children: D("auth.register.username", "Username")
268
+ }), /* @__PURE__ */ C("div", {
266
269
  className: "relative",
267
- children: [/* @__PURE__ */ x("div", {
270
+ children: [/* @__PURE__ */ S("div", {
268
271
  className: "absolute inset-y-0 left-0 pl-3.5 flex items-center pointer-events-none",
269
- children: /* @__PURE__ */ x(m, { className: "w-5 h-5 text-[var(--color-text-tertiary)]" })
270
- }), /* @__PURE__ */ x("input", {
272
+ children: /* @__PURE__ */ S(h, { className: "size-5 text-[var(--color-text-tertiary)]" })
273
+ }), /* @__PURE__ */ S("input", {
271
274
  id: "username",
272
275
  type: "text",
273
276
  required: !0,
274
277
  "aria-required": "true",
275
278
  autoComplete: "username",
276
- value: N.username,
277
- onChange: (e) => P({
278
- ...N,
279
+ value: P.username,
280
+ onChange: (e) => F({
281
+ ...P,
279
282
  username: e.target.value
280
283
  }),
281
284
  className: "block w-full pl-[3.5rem] pr-4 py-3 rounded-xl border border-[var(--color-border-default)] bg-[var(--color-bg-surface)] text-[var(--color-text-primary)] placeholder:text-[var(--color-text-tertiary)] focus:outline-none focus:ring-2 focus:ring-action-primary-bg/20 focus:border-action-primary-bg transition-all",
282
- placeholder: E("auth.register.usernamePlaceholder", "Choose a username")
285
+ placeholder: D("auth.register.usernamePlaceholder", "Choose a username")
283
286
  })]
284
287
  })]
285
288
  }),
286
- /* @__PURE__ */ S("div", {
289
+ /* @__PURE__ */ C("div", {
287
290
  className: "space-y-2",
288
- children: [/* @__PURE__ */ x("label", {
291
+ children: [/* @__PURE__ */ S("label", {
289
292
  htmlFor: "email",
290
293
  className: "block text-sm font-medium text-[var(--color-text-primary)]",
291
- children: E("auth.register.email", "Email")
292
- }), /* @__PURE__ */ S("div", {
294
+ children: D("auth.register.email", "Email")
295
+ }), /* @__PURE__ */ C("div", {
293
296
  className: "relative",
294
- children: [/* @__PURE__ */ x("div", {
297
+ children: [/* @__PURE__ */ S("div", {
295
298
  className: "absolute inset-y-0 left-0 pl-3.5 flex items-center pointer-events-none",
296
- children: /* @__PURE__ */ x(o, { className: "w-5 h-5 text-[var(--color-text-tertiary)]" })
297
- }), /* @__PURE__ */ x("input", {
299
+ children: /* @__PURE__ */ S(s, { className: "size-5 text-[var(--color-text-tertiary)]" })
300
+ }), /* @__PURE__ */ S("input", {
298
301
  id: "email",
299
302
  type: "email",
300
303
  required: !0,
301
304
  "aria-required": "true",
302
305
  autoComplete: "email",
303
- value: N.email,
304
- onChange: (e) => P({
305
- ...N,
306
+ value: P.email,
307
+ onChange: (e) => F({
308
+ ...P,
306
309
  email: e.target.value
307
310
  }),
308
311
  className: "block w-full pl-[3.5rem] pr-4 py-3 rounded-xl border border-[var(--color-border-default)] bg-[var(--color-bg-surface)] text-[var(--color-text-primary)] placeholder:text-[var(--color-text-tertiary)] focus:outline-none focus:ring-2 focus:ring-action-primary-bg/20 focus:border-action-primary-bg transition-all",
309
- placeholder: E("auth.register.emailPlaceholder", "you@example.com")
312
+ placeholder: D("auth.register.emailPlaceholder", "you@example.com")
310
313
  })]
311
314
  })]
312
315
  }),
313
- /* @__PURE__ */ S("div", {
316
+ /* @__PURE__ */ C("div", {
314
317
  className: "space-y-2",
315
318
  children: [
316
- /* @__PURE__ */ x("label", {
319
+ /* @__PURE__ */ S("label", {
317
320
  htmlFor: "password",
318
321
  className: "block text-sm font-medium text-[var(--color-text-primary)]",
319
- children: E("auth.register.password", "Password")
322
+ children: D("auth.register.password", "Password")
320
323
  }),
321
- /* @__PURE__ */ S("div", {
324
+ /* @__PURE__ */ C("div", {
322
325
  className: "relative",
323
326
  children: [
324
- /* @__PURE__ */ x("div", {
327
+ /* @__PURE__ */ S("div", {
325
328
  className: "absolute inset-y-0 left-0 pl-3.5 flex items-center pointer-events-none",
326
- children: /* @__PURE__ */ x(d, { className: "w-5 h-5 text-[var(--color-text-tertiary)]" })
329
+ children: /* @__PURE__ */ S(f, { className: "size-5 text-[var(--color-text-tertiary)]" })
327
330
  }),
328
- /* @__PURE__ */ x("input", {
331
+ /* @__PURE__ */ S("input", {
329
332
  id: "password",
330
- type: j ? "text" : "password",
333
+ type: M ? "text" : "password",
331
334
  required: !0,
332
335
  "aria-required": "true",
333
336
  autoComplete: "new-password",
334
- value: N.password,
335
- onChange: (e) => P({
336
- ...N,
337
+ value: P.password,
338
+ onChange: (e) => F({
339
+ ...P,
337
340
  password: e.target.value
338
341
  }),
339
342
  className: "block w-full pl-[3.5rem] pr-12 py-3 rounded-xl border border-[var(--color-border-default)] bg-[var(--color-bg-surface)] text-[var(--color-text-primary)] placeholder:text-[var(--color-text-tertiary)] focus:outline-none focus:ring-2 focus:ring-action-primary-bg/20 focus:border-action-primary-bg transition-all",
340
- placeholder: E("auth.register.passwordPlaceholder", "Create a strong password")
343
+ placeholder: D("auth.register.passwordPlaceholder", "Create a strong password")
341
344
  }),
342
- /* @__PURE__ */ x("button", {
345
+ /* @__PURE__ */ S("button", {
343
346
  type: "button",
344
- onClick: () => M(!j),
345
- "aria-label": j ? "Hide password" : "Show password",
347
+ onClick: () => N(!M),
348
+ "aria-label": M ? "Hide password" : "Show password",
346
349
  className: "absolute inset-y-0 right-0 pr-3.5 flex items-center text-[var(--color-text-tertiary)] hover:text-[var(--color-text-secondary)] transition-colors",
347
- children: x(j ? c : s, { className: "w-5 h-5" })
350
+ children: S(M ? l : c, { className: "size-5" })
348
351
  })
349
352
  ]
350
353
  }),
351
- N.password && /* @__PURE__ */ S("div", {
354
+ P.password && /* @__PURE__ */ C("div", {
352
355
  className: "space-y-3 pt-2",
353
- children: [/* @__PURE__ */ S("div", {
356
+ children: [/* @__PURE__ */ C("div", {
354
357
  className: "space-y-1",
355
- children: [/* @__PURE__ */ x("div", {
358
+ children: [/* @__PURE__ */ S("div", {
356
359
  className: "h-1.5 bg-[var(--color-bg-sunken)] rounded-full overflow-hidden",
357
- children: /* @__PURE__ */ x("div", { className: `h-full ${X.color} ${X.width} transition-all duration-300` })
358
- }), /* @__PURE__ */ S("p", {
360
+ children: /* @__PURE__ */ S("div", { className: `h-full ${Z.color} ${Z.width} transition-all duration-300` })
361
+ }), /* @__PURE__ */ C("p", {
359
362
  className: "text-xs text-[var(--color-text-tertiary)] capitalize",
360
363
  children: [
361
- E("auth.register.passwordStrength", "Password strength:"),
364
+ D("auth.register.passwordStrength", "Password strength:"),
362
365
  " ",
363
- /* @__PURE__ */ x("span", {
366
+ /* @__PURE__ */ S("span", {
364
367
  className: "font-medium",
365
- children: X.level
368
+ children: Z.level
366
369
  })
367
370
  ]
368
371
  })]
369
- }), /* @__PURE__ */ x("div", {
372
+ }), /* @__PURE__ */ S("div", {
370
373
  className: "grid grid-cols-2 gap-2",
371
- children: Y.map((e, t) => /* @__PURE__ */ S("div", {
374
+ children: X.map((e) => /* @__PURE__ */ C("div", {
372
375
  className: "flex items-center gap-2",
373
- children: [e.met ? /* @__PURE__ */ x(a, { className: "w-4 h-4 text-status-success-text" }) : /* @__PURE__ */ x(ee, { className: "w-4 h-4 text-[var(--color-text-tertiary)]" }), /* @__PURE__ */ x("span", {
376
+ children: [e.met ? /* @__PURE__ */ S(o, { className: "size-4 text-status-success-text" }) : /* @__PURE__ */ S(ee, { className: "size-4 text-[var(--color-text-tertiary)]" }), /* @__PURE__ */ S("span", {
374
377
  className: `text-xs ${e.met ? "text-status-success-text" : "text-[var(--color-text-tertiary)]"}`,
375
378
  children: e.label
376
379
  })]
377
- }, t))
380
+ }, e.label))
378
381
  })]
379
382
  })
380
383
  ]
381
384
  }),
382
- /* @__PURE__ */ S("p", {
385
+ /* @__PURE__ */ C("p", {
383
386
  className: "text-xs text-[var(--color-text-tertiary)] leading-relaxed",
384
387
  children: [
385
- E("auth.register.agreeToTerms", "By creating an account, you agree to our"),
388
+ D("auth.register.agreeToTerms", "By creating an account, you agree to our"),
386
389
  " ",
387
- /* @__PURE__ */ x("a", {
390
+ /* @__PURE__ */ S("a", {
388
391
  href: "/legal/terms",
389
392
  className: "text-text-link hover:underline",
390
- children: E("auth.register.termsOfService", "Terms of Service")
393
+ children: D("auth.register.termsOfService", "Terms of Service")
391
394
  }),
392
395
  " ",
393
- E("auth.register.and", "and"),
396
+ D("auth.register.and", "and"),
394
397
  " ",
395
- /* @__PURE__ */ x("a", {
398
+ /* @__PURE__ */ S("a", {
396
399
  href: "/legal/privacy",
397
400
  className: "text-text-link hover:underline",
398
- children: E("auth.register.privacyPolicy", "Privacy Policy")
401
+ children: D("auth.register.privacyPolicy", "Privacy Policy")
399
402
  }),
400
403
  "."
401
404
  ]
402
405
  }),
403
- /* @__PURE__ */ x(ne, { onVerify: W }),
404
- /* @__PURE__ */ x("button", {
406
+ /* @__PURE__ */ S(_, { onVerify: G }),
407
+ /* @__PURE__ */ S("button", {
405
408
  type: "submit",
406
- disabled: D,
409
+ disabled: O,
407
410
  className: "auth-primary-button flex w-full items-center justify-center gap-2 px-4 py-3 font-semibold",
408
- children: D ? /* @__PURE__ */ S(b, { children: [/* @__PURE__ */ x(p, { className: "w-5 h-5 animate-spin" }), /* @__PURE__ */ x("span", { children: E("auth.register.creatingAccount", "Creating account...") })] }) : E("auth.register.createAccountBtn", "Create account")
411
+ children: O ? /* @__PURE__ */ C(x, { children: [/* @__PURE__ */ S(m, { className: "size-5 animate-spin" }), /* @__PURE__ */ S("span", { children: D("auth.register.creatingAccount", "Creating account...") })] }) : D("auth.register.createAccountBtn", "Create account")
409
412
  })
410
413
  ]
411
414
  }),
412
- /* @__PURE__ */ S("div", {
415
+ /* @__PURE__ */ C("div", {
413
416
  className: "relative my-8",
414
- children: [/* @__PURE__ */ x("div", {
417
+ children: [/* @__PURE__ */ S("div", {
415
418
  className: "absolute inset-0 flex items-center",
416
- children: /* @__PURE__ */ x("div", { className: "w-full border-t border-[var(--color-border-default)]" })
417
- }), /* @__PURE__ */ x("div", {
419
+ children: /* @__PURE__ */ S("div", { className: "w-full border-t border-[var(--color-border-default)]" })
420
+ }), /* @__PURE__ */ S("div", {
418
421
  className: "relative flex justify-center",
419
- children: /* @__PURE__ */ x("span", {
422
+ children: /* @__PURE__ */ S("span", {
420
423
  className: "px-4 bg-[var(--color-bg-canvas)] text-sm text-[var(--color-text-tertiary)]",
421
- children: E("auth.register.orSignUpWith", "or sign up with")
424
+ children: D("auth.register.orSignUpWith", "or sign up with")
422
425
  })
423
426
  })]
424
427
  }),
425
- V && /* @__PURE__ */ S("div", {
428
+ H && /* @__PURE__ */ C("div", {
426
429
  className: "flex items-start gap-3 p-4 rounded-xl border bg-status-error-bg-subtle border-status-error-border",
427
- children: [/* @__PURE__ */ x(i, { className: "w-5 h-5 flex-shrink-0 mt-0.5 text-status-error-text" }), /* @__PURE__ */ x("p", {
430
+ children: [/* @__PURE__ */ S(a, { className: "size-5 flex-shrink-0 mt-0.5 text-status-error-text" }), /* @__PURE__ */ S("p", {
428
431
  className: "text-sm text-status-error-text",
429
- children: V
432
+ children: H
430
433
  })]
431
434
  }),
432
- /* @__PURE__ */ x("div", {
435
+ /* @__PURE__ */ S("div", {
433
436
  className: "grid grid-cols-3 gap-3",
434
- children: se.map((e) => /* @__PURE__ */ S("button", {
437
+ children: se.map((e) => /* @__PURE__ */ C("button", {
435
438
  type: "button",
436
439
  onClick: e.onClick,
437
440
  disabled: e.disabled,
438
441
  title: e.tooltip,
439
442
  className: `flex items-center justify-center gap-2 px-4 py-3 rounded-xl border transition-all duration-200 group ${e.disabled ? "border-[var(--color-border-subtle)] bg-[var(--color-bg-disabled)] cursor-not-allowed opacity-50" : "border-[var(--color-border-default)] bg-[var(--color-bg-surface)] hover:bg-[var(--color-bg-sunken)] hover:border-[var(--color-border-strong)]"}`,
440
- children: [/* @__PURE__ */ x(e.icon, { className: `w-5 h-5 ${e.disabled ? "opacity-50" : ""}` }), /* @__PURE__ */ x("span", {
443
+ children: [/* @__PURE__ */ S(e.icon, { className: `size-5 ${e.disabled ? "opacity-50" : ""}` }), /* @__PURE__ */ S("span", {
441
444
  className: `sr-only sm:not-sr-only text-sm font-medium transition-colors hidden sm:inline ${e.disabled ? "text-[var(--color-text-disabled)]" : "text-[var(--color-text-secondary)] group-hover:text-[var(--color-text-primary)]"}`,
442
445
  children: e.name
443
446
  })]
444
447
  }, e.name))
445
448
  }),
446
- /* @__PURE__ */ S("p", {
449
+ /* @__PURE__ */ C("p", {
447
450
  className: "mt-8 text-center text-sm text-[var(--color-text-secondary)]",
448
451
  children: [
449
- E("auth.register.alreadyHaveAccount", "Already have an account?"),
452
+ D("auth.register.alreadyHaveAccount", "Already have an account?"),
450
453
  " ",
451
- /* @__PURE__ */ x("button", {
452
- onClick: () => w("/auth/login"),
454
+ /* @__PURE__ */ S("button", {
455
+ type: "button",
456
+ onClick: () => T("/auth/login"),
453
457
  className: "font-semibold text-text-link hover:text-text-linkHover transition-colors",
454
- children: E("auth.register.signIn", "Sign in")
458
+ children: D("auth.register.signIn", "Sign in")
455
459
  })
456
460
  ]
457
461
  })
@@ -459,6 +463,6 @@ function C() {
459
463
  });
460
464
  }
461
465
  //#endregion
462
- export { C as RegisterPage };
466
+ export { w as RegisterPage };
463
467
 
464
468
  //# sourceMappingURL=RegisterPage.js.map