@alfadocs/ui-kit-debug 1.78.0 → 1.80.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/_chunks/{address-fields-BUPRs3n-.js → address-fields-GnoSkvh6.js} +2 -2
- package/dist/_chunks/{address-fields-BUPRs3n-.js.map → address-fields-GnoSkvh6.js.map} +1 -1
- package/dist/_chunks/{anamnesis-summary-rows-vNDyE5HW.js → anamnesis-summary-rows-lONg-zja.js} +2 -2
- package/dist/_chunks/{anamnesis-summary-rows-vNDyE5HW.js.map → anamnesis-summary-rows-lONg-zja.js.map} +1 -1
- package/dist/_chunks/{bishop-score-CdbU9Nl4.js → bishop-score-C5di6oAV.js} +2 -2
- package/dist/_chunks/{bishop-score-CdbU9Nl4.js.map → bishop-score-C5di6oAV.js.map} +1 -1
- package/dist/_chunks/{bmi-calculator-DnfiDh4Q.js → bmi-calculator-BIExHBZV.js} +2 -2
- package/dist/_chunks/{bmi-calculator-DnfiDh4Q.js.map → bmi-calculator-BIExHBZV.js.map} +1 -1
- package/dist/_chunks/{booking-Cz_QjIJe.js → booking-By4I_1A-.js} +1766 -1749
- package/dist/_chunks/booking-By4I_1A-.js.map +1 -0
- package/dist/_chunks/{calendar-appointment-editor-dialog-cvUpUjj-.js → calendar-appointment-editor-dialog-DhTTWgXw.js} +3 -3
- package/dist/_chunks/{calendar-appointment-editor-dialog-cvUpUjj-.js.map → calendar-appointment-editor-dialog-DhTTWgXw.js.map} +1 -1
- package/dist/_chunks/{cycle-calculator-HO3s5InI.js → cycle-calculator-CQkjVSD2.js} +2 -2
- package/dist/_chunks/{cycle-calculator-HO3s5InI.js.map → cycle-calculator-CQkjVSD2.js.map} +1 -1
- package/dist/_chunks/{due-date-calculator-CDWTSblh.js → due-date-calculator-NjTlmoFK.js} +2 -2
- package/dist/_chunks/{due-date-calculator-CDWTSblh.js.map → due-date-calculator-NjTlmoFK.js.map} +1 -1
- package/dist/_chunks/{fetal-weight-CrtBFJl-.js → fetal-weight-Brl3n4LN.js} +2 -2
- package/dist/_chunks/{fetal-weight-CrtBFJl-.js.map → fetal-weight-Brl3n4LN.js.map} +1 -1
- package/dist/_chunks/{forgot-password-form-BSOZVrZG.js → forgot-password-form-BQPvDS7i.js} +2 -2
- package/dist/_chunks/{forgot-password-form-BSOZVrZG.js.map → forgot-password-form-BQPvDS7i.js.map} +1 -1
- package/dist/_chunks/form-field-CyHfOVKF.js +185 -0
- package/dist/_chunks/form-field-CyHfOVKF.js.map +1 -0
- package/dist/_chunks/{gestational-age-calculator-CTHeJJdb.js → gestational-age-calculator-Dr9hdDta.js} +2 -2
- package/dist/_chunks/{gestational-age-calculator-CTHeJJdb.js.map → gestational-age-calculator-Dr9hdDta.js.map} +1 -1
- package/dist/_chunks/{hcg-doubling-BBk-a33g.js → hcg-doubling-K41Wy7LB.js} +2 -2
- package/dist/_chunks/{hcg-doubling-BBk-a33g.js.map → hcg-doubling-K41Wy7LB.js.map} +1 -1
- package/dist/_chunks/{help-me-write-templates-Ds1FY-WY.js → help-me-write-templates-BJSf24xS.js} +2 -2
- package/dist/_chunks/{help-me-write-templates-Ds1FY-WY.js.map → help-me-write-templates-BJSf24xS.js.map} +1 -1
- package/dist/_chunks/key-round-DIgsnJSg.js +21 -0
- package/dist/_chunks/key-round-DIgsnJSg.js.map +1 -0
- package/dist/_chunks/{kit-extensions-sNTZWkoo.js → kit-extensions-a0G4COFH.js} +6 -6
- package/dist/_chunks/{kit-extensions-sNTZWkoo.js.map → kit-extensions-a0G4COFH.js.map} +1 -1
- package/dist/_chunks/login-dev-card-CvLHj-_N.js +353 -0
- package/dist/_chunks/login-dev-card-CvLHj-_N.js.map +1 -0
- package/dist/_chunks/{practice-results-BnY2EkzI.js → practice-results-CtOanuzZ.js} +659 -615
- package/dist/_chunks/practice-results-CtOanuzZ.js.map +1 -0
- package/dist/_chunks/{pregnancy-dating-JBAUbM40.js → pregnancy-dating-BHvfDxz4.js} +2 -2
- package/dist/_chunks/{pregnancy-dating-JBAUbM40.js.map → pregnancy-dating-BHvfDxz4.js.map} +1 -1
- package/dist/_chunks/{pregnancy-weight-gain--Bqv6AWu.js → pregnancy-weight-gain-BeQRxwdP.js} +2 -2
- package/dist/_chunks/{pregnancy-weight-gain--Bqv6AWu.js.map → pregnancy-weight-gain-BeQRxwdP.js.map} +1 -1
- package/dist/_chunks/{radiograph-panel.agent-DQh2SX8G.js → radiograph-panel.agent-BQ95uFCd.js} +2 -2
- package/dist/_chunks/{radiograph-panel.agent-DQh2SX8G.js.map → radiograph-panel.agent-BQ95uFCd.js.map} +1 -1
- package/dist/_chunks/registration-form-CNBfUduG.js +1337 -0
- package/dist/_chunks/registration-form-CNBfUduG.js.map +1 -0
- package/dist/_chunks/reset-password-form-Cf9QPEJu.js +367 -0
- package/dist/_chunks/reset-password-form-Cf9QPEJu.js.map +1 -0
- package/dist/_chunks/{send-registration-link-form-__DWY62q.js → send-registration-link-form-vTn1HxjA.js} +2 -2
- package/dist/_chunks/{send-registration-link-form-__DWY62q.js.map → send-registration-link-form-vTn1HxjA.js.map} +1 -1
- package/dist/_chunks/{task-editor-CRhfwP9T.js → task-editor-Cpw-NmND.js} +2 -2
- package/dist/_chunks/{task-editor-CRhfwP9T.js.map → task-editor-Cpw-NmND.js.map} +1 -1
- package/dist/_chunks/{unit-converter-D59L-gkf.js → unit-converter-BH5ueIhT.js} +2 -2
- package/dist/_chunks/{unit-converter-D59L-gkf.js.map → unit-converter-BH5ueIhT.js.map} +1 -1
- package/dist/_chunks/{voice-control-panel-DQJwe6_Q.js → voice-control-panel-BziKE-KK.js} +2 -2
- package/dist/_chunks/{voice-control-panel-DQJwe6_Q.js.map → voice-control-panel-BziKE-KK.js.map} +1 -1
- package/dist/_chunks/{workflow-webhook-action-BvVPZVpG.js → workflow-webhook-action-DulCpCRz.js} +96 -111
- package/dist/_chunks/workflow-webhook-action-DulCpCRz.js.map +1 -0
- package/dist/agent-catalog.json +91 -5
- package/dist/agent-i18n/en.json +11 -2
- package/dist/components/address-fields/index.js +1 -1
- package/dist/components/bishop-score/index.js +1 -1
- package/dist/components/bmi-calculator/index.js +1 -1
- package/dist/components/booking/booking-types.d.ts +16 -1
- package/dist/components/booking/booking-types.d.ts.map +1 -1
- package/dist/components/booking/booking.d.ts.map +1 -1
- package/dist/components/booking/cascade.d.ts +3 -0
- package/dist/components/booking/cascade.d.ts.map +1 -1
- package/dist/components/booking/details-form.d.ts +2 -0
- package/dist/components/booking/details-form.d.ts.map +1 -1
- package/dist/components/booking/index.js +1 -1
- package/dist/components/cycle-calculator/index.js +1 -1
- package/dist/components/due-date-calculator/index.js +1 -1
- package/dist/components/fetal-weight/index.js +1 -1
- package/dist/components/form-field/form-field.d.ts +6 -0
- package/dist/components/form-field/form-field.d.ts.map +1 -1
- package/dist/components/form-field/index.js +1 -1
- package/dist/components/gestational-age-calculator/index.js +1 -1
- package/dist/components/hcg-doubling/index.js +1 -1
- package/dist/components/index.d.ts +1 -0
- package/dist/components/index.d.ts.map +1 -1
- package/dist/components/practice-results/index.js +1 -1
- package/dist/components/practice-results/practice-results.d.ts +19 -2
- package/dist/components/practice-results/practice-results.d.ts.map +1 -1
- package/dist/components/pregnancy-dating/index.js +1 -1
- package/dist/components/pregnancy-weight-gain/index.js +1 -1
- package/dist/components/radiograph-panel/index.js +1 -1
- package/dist/components/rich-text-editor/index.js +1 -1
- package/dist/components/task-editor/index.js +1 -1
- package/dist/components/unit-converter/index.js +1 -1
- package/dist/components/voice-control-panel/index.js +1 -1
- package/dist/i18n/locales/ar.d.ts +28 -0
- package/dist/i18n/locales/ar.d.ts.map +1 -1
- package/dist/i18n/locales/ar.js +30 -2
- package/dist/i18n/locales/ar.js.map +1 -1
- package/dist/i18n/locales/de.d.ts +28 -0
- package/dist/i18n/locales/de.d.ts.map +1 -1
- package/dist/i18n/locales/de.js +30 -2
- package/dist/i18n/locales/de.js.map +1 -1
- package/dist/i18n/locales/el.d.ts +28 -0
- package/dist/i18n/locales/el.d.ts.map +1 -1
- package/dist/i18n/locales/el.js +30 -2
- package/dist/i18n/locales/el.js.map +1 -1
- package/dist/i18n/locales/en.d.ts +28 -0
- package/dist/i18n/locales/en.d.ts.map +1 -1
- package/dist/i18n/locales/en.js +29 -1
- package/dist/i18n/locales/en.js.map +1 -1
- package/dist/i18n/locales/es.d.ts +28 -0
- package/dist/i18n/locales/es.d.ts.map +1 -1
- package/dist/i18n/locales/es.js +30 -2
- package/dist/i18n/locales/es.js.map +1 -1
- package/dist/i18n/locales/fr.d.ts +28 -0
- package/dist/i18n/locales/fr.d.ts.map +1 -1
- package/dist/i18n/locales/fr.js +30 -2
- package/dist/i18n/locales/fr.js.map +1 -1
- package/dist/i18n/locales/hi.d.ts +28 -0
- package/dist/i18n/locales/hi.d.ts.map +1 -1
- package/dist/i18n/locales/hi.js +30 -2
- package/dist/i18n/locales/hi.js.map +1 -1
- package/dist/i18n/locales/it.d.ts +28 -0
- package/dist/i18n/locales/it.d.ts.map +1 -1
- package/dist/i18n/locales/it.js +30 -2
- package/dist/i18n/locales/it.js.map +1 -1
- package/dist/i18n/locales/ja.d.ts +28 -0
- package/dist/i18n/locales/ja.d.ts.map +1 -1
- package/dist/i18n/locales/ja.js +30 -2
- package/dist/i18n/locales/ja.js.map +1 -1
- package/dist/i18n/locales/nl.d.ts +28 -0
- package/dist/i18n/locales/nl.d.ts.map +1 -1
- package/dist/i18n/locales/nl.js +30 -2
- package/dist/i18n/locales/nl.js.map +1 -1
- package/dist/i18n/locales/pl.d.ts +28 -0
- package/dist/i18n/locales/pl.d.ts.map +1 -1
- package/dist/i18n/locales/pl.js +30 -2
- package/dist/i18n/locales/pl.js.map +1 -1
- package/dist/i18n/locales/pt.d.ts +28 -0
- package/dist/i18n/locales/pt.d.ts.map +1 -1
- package/dist/i18n/locales/pt.js +30 -2
- package/dist/i18n/locales/pt.js.map +1 -1
- package/dist/i18n/locales/ro.d.ts +28 -0
- package/dist/i18n/locales/ro.d.ts.map +1 -1
- package/dist/i18n/locales/ro.js +30 -2
- package/dist/i18n/locales/ro.js.map +1 -1
- package/dist/i18n/locales/ru.d.ts +28 -0
- package/dist/i18n/locales/ru.d.ts.map +1 -1
- package/dist/i18n/locales/ru.js +30 -2
- package/dist/i18n/locales/ru.js.map +1 -1
- package/dist/i18n/locales/sq.d.ts +28 -0
- package/dist/i18n/locales/sq.d.ts.map +1 -1
- package/dist/i18n/locales/sq.js +30 -2
- package/dist/i18n/locales/sq.js.map +1 -1
- package/dist/i18n/locales/sv.d.ts +28 -0
- package/dist/i18n/locales/sv.d.ts.map +1 -1
- package/dist/i18n/locales/sv.js +30 -2
- package/dist/i18n/locales/sv.js.map +1 -1
- package/dist/i18n/locales/tr.d.ts +28 -0
- package/dist/i18n/locales/tr.d.ts.map +1 -1
- package/dist/i18n/locales/tr.js +30 -2
- package/dist/i18n/locales/tr.js.map +1 -1
- package/dist/i18n/locales/zh.d.ts +28 -0
- package/dist/i18n/locales/zh.d.ts.map +1 -1
- package/dist/i18n/locales/zh.js +30 -2
- package/dist/i18n/locales/zh.js.map +1 -1
- package/dist/index.js +90 -87
- package/dist/index.js.map +1 -1
- package/dist/locales/ar.json +30 -2
- package/dist/locales/de.json +30 -2
- package/dist/locales/el.json +30 -2
- package/dist/locales/en.json +29 -1
- package/dist/locales/es.json +30 -2
- package/dist/locales/fr.json +30 -2
- package/dist/locales/hi.json +30 -2
- package/dist/locales/it.json +30 -2
- package/dist/locales/ja.json +30 -2
- package/dist/locales/nl.json +30 -2
- package/dist/locales/pl.json +30 -2
- package/dist/locales/pt.json +30 -2
- package/dist/locales/ro.json +30 -2
- package/dist/locales/ru.json +30 -2
- package/dist/locales/sq.json +30 -2
- package/dist/locales/sv.json +30 -2
- package/dist/locales/tr.json +30 -2
- package/dist/locales/zh.json +30 -2
- package/dist/patterns/_shared/password-policy.d.ts +3 -0
- package/dist/patterns/_shared/password-policy.d.ts.map +1 -0
- package/dist/patterns/anamnesis/index.js +1 -1
- package/dist/patterns/calendar/index.js +1 -1
- package/dist/patterns/forgot-password-form/index.js +1 -1
- package/dist/patterns/help-me-write-templates/index.js +1 -1
- package/dist/patterns/login-form/index.js +1 -1
- package/dist/patterns/login-form/login-form.d.ts +24 -7
- package/dist/patterns/login-form/login-form.d.ts.map +1 -1
- package/dist/patterns/registration-form/index.d.ts +1 -1
- package/dist/patterns/registration-form/index.d.ts.map +1 -1
- package/dist/patterns/registration-form/index.js +1 -1
- package/dist/patterns/registration-form/registration-form.d.ts +27 -0
- package/dist/patterns/registration-form/registration-form.d.ts.map +1 -1
- package/dist/patterns/reset-password-form/index.d.ts +3 -0
- package/dist/patterns/reset-password-form/index.d.ts.map +1 -0
- package/dist/patterns/reset-password-form/index.js +6 -0
- package/dist/patterns/reset-password-form/index.js.map +1 -0
- package/dist/patterns/reset-password-form/reset-password-form.d.ts +108 -0
- package/dist/patterns/reset-password-form/reset-password-form.d.ts.map +1 -0
- package/dist/patterns/send-registration-link-form/index.js +1 -1
- package/dist/patterns/workflow-webhook-action/index.js +1 -1
- package/dist/tokens.css +1 -1
- package/package.json +5 -1
- package/dist/_chunks/booking-Cz_QjIJe.js.map +0 -1
- package/dist/_chunks/form-field-Ani72sVY.js +0 -176
- package/dist/_chunks/form-field-Ani72sVY.js.map +0 -1
- package/dist/_chunks/login-dev-card-DRxTPkE9.js +0 -332
- package/dist/_chunks/login-dev-card-DRxTPkE9.js.map +0 -1
- package/dist/_chunks/practice-results-BnY2EkzI.js.map +0 -1
- package/dist/_chunks/registration-form-xORq2s4p.js +0 -1310
- package/dist/_chunks/registration-form-xORq2s4p.js.map +0 -1
- package/dist/_chunks/workflow-webhook-action-BvVPZVpG.js.map +0 -1
|
@@ -0,0 +1,367 @@
|
|
|
1
|
+
import { jsx as r, jsxs as i, Fragment as O } from "react/jsx-runtime";
|
|
2
|
+
import { forwardRef as Ls, useId as l, useState as m, useRef as p, useMemo as Ns, useEffect as B } from "react";
|
|
3
|
+
import { useTranslation as _s } from "react-i18next";
|
|
4
|
+
import { c as ws } from "./index-D2ZczOXr.js";
|
|
5
|
+
import { A as u } from "./alert-9kEwDza3.js";
|
|
6
|
+
import { B as D } from "./button-DohK_Ak_.js";
|
|
7
|
+
import { C as ms } from "./card-BA4Ig_kn.js";
|
|
8
|
+
import { E as ks } from "./email-input-C7THAwh2.js";
|
|
9
|
+
import { E as Vs } from "./error-summary-mGxIyDAY.js";
|
|
10
|
+
import { F as L } from "./form-field-CyHfOVKF.js";
|
|
11
|
+
import { P as us } from "./password-input-BokZ_rnT.js";
|
|
12
|
+
import { u as Hs } from "./use-password-requirements-C8DdwPEy.js";
|
|
13
|
+
import { i as js } from "./safe-href-5dbsfbQn.js";
|
|
14
|
+
import { u as zs } from "./use-state-backed-input-DhRQo6gM.js";
|
|
15
|
+
import { u as Ws } from "./use-field-match-C8ug3sdQ.js";
|
|
16
|
+
import { u as $s, a as Gs, A as Us, b as Ys, E as Js, c as Ks } from "./auth-form-parts-B3GWChvG.js";
|
|
17
|
+
import { u as Qs, a as Xs, b as Zs } from "./use-registration-submit-CLGHxwoT.js";
|
|
18
|
+
const sr = {
|
|
19
|
+
minLength: 12,
|
|
20
|
+
uppercase: !0,
|
|
21
|
+
lowercase: !0,
|
|
22
|
+
digit: !0,
|
|
23
|
+
charset: "ascii"
|
|
24
|
+
}, b = [
|
|
25
|
+
"password",
|
|
26
|
+
"passwordConfirm"
|
|
27
|
+
], rr = ws(
|
|
28
|
+
"ds:mx-auto ds:w-full ds:max-w-[400px] ds:text-start ds:text-[var(--foreground)]"
|
|
29
|
+
), fs = ws(
|
|
30
|
+
"ds:focus-visible:outline-solid ds:focus-visible:outline-[length:var(--focus-ring-width)] ds:focus-visible:outline-[var(--ring)] ds:focus-visible:outline-offset-[length:var(--focus-ring-offset)] ds:forced-colors:focus-visible:outline-[CanvasText]"
|
|
31
|
+
), or = "", er = "", ar = { 1: "h2", 2: "h3", 3: "h4" }, tr = (e) => Object.values(e).some(Boolean), ps = (e) => b.find((P) => e[P]) ?? (e.form ? "form" : void 0), nr = Ls(
|
|
32
|
+
({
|
|
33
|
+
state: e = "form",
|
|
34
|
+
title: P,
|
|
35
|
+
description: hs,
|
|
36
|
+
headingLevel: x = 1,
|
|
37
|
+
showLogo: gs = !0,
|
|
38
|
+
logoMotion: Fs = "assemble",
|
|
39
|
+
children: N,
|
|
40
|
+
email: w,
|
|
41
|
+
loginHref: vs,
|
|
42
|
+
requestHref: Cs,
|
|
43
|
+
errors: c,
|
|
44
|
+
submitLabel: bs,
|
|
45
|
+
submitting: Ps = !1,
|
|
46
|
+
onSubmit: I,
|
|
47
|
+
fieldNames: R,
|
|
48
|
+
action: xs,
|
|
49
|
+
hiddenFields: Is,
|
|
50
|
+
className: Rs,
|
|
51
|
+
...Es
|
|
52
|
+
}, ys) => {
|
|
53
|
+
const { t: o } = _s("ui"), _ = l(), h = l(), g = l(), As = l(), k = l(), V = l(), H = l(), F = R !== void 0, Ss = {
|
|
54
|
+
password: k,
|
|
55
|
+
passwordConfirm: V
|
|
56
|
+
}, [t, E] = m({
|
|
57
|
+
password: "",
|
|
58
|
+
passwordConfirm: ""
|
|
59
|
+
}), [Ts, y] = m({}), [j, z] = m(!1), [f, W] = m(
|
|
60
|
+
() => c ?? {}
|
|
61
|
+
), $ = (s, a) => {
|
|
62
|
+
E((n) => ({ ...n, [s]: a })), W(
|
|
63
|
+
(n) => n[s] ? { ...n, [s]: void 0 } : n
|
|
64
|
+
);
|
|
65
|
+
}, G = (s) => y(
|
|
66
|
+
(a) => a[s] ? a : { ...a, [s]: !0 }
|
|
67
|
+
), U = () => {
|
|
68
|
+
E({ password: "", passwordConfirm: "" }), y({});
|
|
69
|
+
}, Y = Hs(sr), A = Ws({
|
|
70
|
+
value: t.password,
|
|
71
|
+
confirmValue: t.passwordConfirm,
|
|
72
|
+
kind: "password",
|
|
73
|
+
submitted: j
|
|
74
|
+
}), J = {
|
|
75
|
+
password: t.password === "" || !Y.every((s) => s.test(t.password)),
|
|
76
|
+
passwordConfirm: t.passwordConfirm === "" || !A.matches
|
|
77
|
+
}, K = (s) => j || Ts[s] === !0, qs = {
|
|
78
|
+
password: K("password") && J.password ? t.password === "" ? o("resetPasswordForm.passwordRequired") : o("resetPasswordForm.passwordInvalid") : void 0,
|
|
79
|
+
passwordConfirm: t.passwordConfirm === "" ? K("passwordConfirm") ? o("resetPasswordForm.passwordConfirmRequired") : void 0 : A.error
|
|
80
|
+
}, v = (s) => f[s] ?? qs[s], S = p({}), Q = Ns(
|
|
81
|
+
() => ({
|
|
82
|
+
password: (s) => {
|
|
83
|
+
S.current.password = s;
|
|
84
|
+
},
|
|
85
|
+
passwordConfirm: (s) => {
|
|
86
|
+
S.current.passwordConfirm = s;
|
|
87
|
+
}
|
|
88
|
+
}),
|
|
89
|
+
[]
|
|
90
|
+
), X = p(null), T = p(null), Ms = p(null), Z = zs(w ?? "", Ms), [ss] = m(
|
|
91
|
+
() => b.some((s) => !!(c != null && c[s]))
|
|
92
|
+
), d = Qs(
|
|
93
|
+
b,
|
|
94
|
+
v,
|
|
95
|
+
ss
|
|
96
|
+
), Os = Xs(
|
|
97
|
+
f.form,
|
|
98
|
+
d.listed.length > 0
|
|
99
|
+
), [C, rs] = m(() => {
|
|
100
|
+
const s = ss ? void 0 : ps(c ?? {});
|
|
101
|
+
return s ? { target: s } : null;
|
|
102
|
+
});
|
|
103
|
+
B(() => {
|
|
104
|
+
var s, a;
|
|
105
|
+
C && (C.target === "form" ? (s = X.current) == null || s.focus() : (a = S.current[C.target]) == null || a.focus());
|
|
106
|
+
}, [C]);
|
|
107
|
+
const os = e !== "form";
|
|
108
|
+
B(() => {
|
|
109
|
+
os && (E({ password: "", passwordConfirm: "" }), y({}));
|
|
110
|
+
}, [os]);
|
|
111
|
+
const es = p(e === "form");
|
|
112
|
+
B(() => {
|
|
113
|
+
var s;
|
|
114
|
+
e !== "form" && es.current && ((s = T.current) == null || s.focus()), es.current = e === "form";
|
|
115
|
+
}, [e]);
|
|
116
|
+
const as = Zs({
|
|
117
|
+
errors: c,
|
|
118
|
+
submitting: Ps,
|
|
119
|
+
native: F,
|
|
120
|
+
captcha: !1,
|
|
121
|
+
firstProblem: () => b.find((s) => J[s]),
|
|
122
|
+
onRefused: (s) => {
|
|
123
|
+
z(!0), d.open(() => rs({ target: s }));
|
|
124
|
+
},
|
|
125
|
+
// Only a React host gets here: a native post is the browser's own.
|
|
126
|
+
deliver: () => I == null ? void 0 : I({
|
|
127
|
+
password: t.password,
|
|
128
|
+
passwordConfirm: t.passwordConfirm
|
|
129
|
+
}),
|
|
130
|
+
onAnswer: (s) => {
|
|
131
|
+
const a = s;
|
|
132
|
+
W(a), tr(a) && (U(), z(!1), d.open(() => {
|
|
133
|
+
const n = ps(a);
|
|
134
|
+
n && rs({ target: n });
|
|
135
|
+
}));
|
|
136
|
+
},
|
|
137
|
+
// The page came back from the browser's cache as it was left: the
|
|
138
|
+
// passwords must not come back with it.
|
|
139
|
+
onRestore: U
|
|
140
|
+
}), { busy: q } = as, Bs = $s("ResetPasswordForm", F, xs), Ds = Gs(
|
|
141
|
+
"ResetPasswordForm",
|
|
142
|
+
F,
|
|
143
|
+
R,
|
|
144
|
+
Is
|
|
145
|
+
), ts = (s) => F ? R[s] : s, ns = (s) => s && js(s) ? s : void 0, ds = ns(vs), is = ns(Cs), M = e === "form", ls = {
|
|
146
|
+
password: o("resetPasswordForm.password"),
|
|
147
|
+
passwordConfirm: o("resetPasswordForm.passwordConfirm")
|
|
148
|
+
}, cs = ar[x];
|
|
149
|
+
return /* @__PURE__ */ r(
|
|
150
|
+
"div",
|
|
151
|
+
{
|
|
152
|
+
ref: ys,
|
|
153
|
+
...Es,
|
|
154
|
+
"data-component": "reset-password-form",
|
|
155
|
+
"data-state": e,
|
|
156
|
+
className: rr({ className: Rs }),
|
|
157
|
+
children: /* @__PURE__ */ r(ms, { variant: "elevated", children: /* @__PURE__ */ i(ms.Body, { className: "ds:flex ds:flex-col ds:gap-[var(--spacing-lg)]", children: [
|
|
158
|
+
/* @__PURE__ */ r(
|
|
159
|
+
Us,
|
|
160
|
+
{
|
|
161
|
+
id: _,
|
|
162
|
+
title: M ? P ?? o("resetPasswordForm.title") : o("resetPasswordForm.pageTitle"),
|
|
163
|
+
description: M ? hs ?? o("resetPasswordForm.description") : void 0,
|
|
164
|
+
level: x,
|
|
165
|
+
showLogo: gs,
|
|
166
|
+
logoMotion: Fs
|
|
167
|
+
}
|
|
168
|
+
),
|
|
169
|
+
N ? /* @__PURE__ */ r(
|
|
170
|
+
"div",
|
|
171
|
+
{
|
|
172
|
+
"data-slot": "host-content",
|
|
173
|
+
className: "ds:flex ds:flex-col ds:gap-[var(--spacing-md)]",
|
|
174
|
+
children: N
|
|
175
|
+
}
|
|
176
|
+
) : null,
|
|
177
|
+
e === "done" && /* @__PURE__ */ i(O, { children: [
|
|
178
|
+
/* @__PURE__ */ i(
|
|
179
|
+
u,
|
|
180
|
+
{
|
|
181
|
+
ref: T,
|
|
182
|
+
variant: "success",
|
|
183
|
+
tabIndex: -1,
|
|
184
|
+
"aria-labelledby": h,
|
|
185
|
+
"aria-describedby": g,
|
|
186
|
+
"data-slot": "result",
|
|
187
|
+
className: fs(),
|
|
188
|
+
children: [
|
|
189
|
+
/* @__PURE__ */ r(u.Title, { id: h, as: cs, children: o("resetPasswordForm.doneTitle") }),
|
|
190
|
+
/* @__PURE__ */ r(u.Description, { id: g, children: w ? o("resetPasswordForm.doneDescriptionEmail", {
|
|
191
|
+
// Isolated left to right, so the address keeps its
|
|
192
|
+
// order inside a right-to-left sentence.
|
|
193
|
+
email: `${or}${w}${er}`
|
|
194
|
+
}) : o("resetPasswordForm.doneDescription") })
|
|
195
|
+
]
|
|
196
|
+
}
|
|
197
|
+
),
|
|
198
|
+
ds && /* @__PURE__ */ r(
|
|
199
|
+
D,
|
|
200
|
+
{
|
|
201
|
+
asChild: !0,
|
|
202
|
+
intent: "primary",
|
|
203
|
+
size: "lg",
|
|
204
|
+
className: "ds:w-full",
|
|
205
|
+
children: /* @__PURE__ */ r("a", { href: ds, "data-action": "login", children: o("resetPasswordForm.signIn") })
|
|
206
|
+
}
|
|
207
|
+
)
|
|
208
|
+
] }),
|
|
209
|
+
e === "expired" && /* @__PURE__ */ i(O, { children: [
|
|
210
|
+
/* @__PURE__ */ i(
|
|
211
|
+
u,
|
|
212
|
+
{
|
|
213
|
+
ref: T,
|
|
214
|
+
variant: "warning",
|
|
215
|
+
announce: "polite",
|
|
216
|
+
tabIndex: -1,
|
|
217
|
+
"aria-labelledby": h,
|
|
218
|
+
"aria-describedby": g,
|
|
219
|
+
"data-slot": "result",
|
|
220
|
+
className: fs(),
|
|
221
|
+
children: [
|
|
222
|
+
/* @__PURE__ */ r(u.Title, { id: h, as: cs, children: o("resetPasswordForm.expiredTitle") }),
|
|
223
|
+
/* @__PURE__ */ r(u.Description, { id: g, children: o("resetPasswordForm.expiredDescription") })
|
|
224
|
+
]
|
|
225
|
+
}
|
|
226
|
+
),
|
|
227
|
+
is && /* @__PURE__ */ r(
|
|
228
|
+
D,
|
|
229
|
+
{
|
|
230
|
+
asChild: !0,
|
|
231
|
+
intent: "primary",
|
|
232
|
+
size: "lg",
|
|
233
|
+
className: "ds:w-full",
|
|
234
|
+
children: /* @__PURE__ */ r("a", { href: is, "data-action": "request-link", children: o("resetPasswordForm.requestLink") })
|
|
235
|
+
}
|
|
236
|
+
)
|
|
237
|
+
] }),
|
|
238
|
+
M && /* @__PURE__ */ i(O, { children: [
|
|
239
|
+
/* @__PURE__ */ i(
|
|
240
|
+
"form",
|
|
241
|
+
{
|
|
242
|
+
noValidate: !0,
|
|
243
|
+
method: "post",
|
|
244
|
+
action: Bs,
|
|
245
|
+
"aria-labelledby": _,
|
|
246
|
+
"aria-busy": q || void 0,
|
|
247
|
+
onSubmit: as.handleSubmit,
|
|
248
|
+
className: "ds:flex ds:flex-col ds:gap-[var(--spacing-md)]",
|
|
249
|
+
children: [
|
|
250
|
+
/* @__PURE__ */ r(
|
|
251
|
+
Vs,
|
|
252
|
+
{
|
|
253
|
+
ref: d.ref,
|
|
254
|
+
headingLevel: x + 1,
|
|
255
|
+
"aria-describedby": f.form ? H : void 0,
|
|
256
|
+
errors: d.listed.map((s) => ({
|
|
257
|
+
field: s,
|
|
258
|
+
message: v(s) ?? "",
|
|
259
|
+
targetId: Ss[s]
|
|
260
|
+
}))
|
|
261
|
+
}
|
|
262
|
+
),
|
|
263
|
+
f.form && /* @__PURE__ */ r(
|
|
264
|
+
Ys,
|
|
265
|
+
{
|
|
266
|
+
ref: X,
|
|
267
|
+
id: H,
|
|
268
|
+
announce: Os,
|
|
269
|
+
children: f.form
|
|
270
|
+
}
|
|
271
|
+
),
|
|
272
|
+
w ? /* @__PURE__ */ r(
|
|
273
|
+
L,
|
|
274
|
+
{
|
|
275
|
+
id: As,
|
|
276
|
+
label: o("resetPasswordForm.email"),
|
|
277
|
+
"data-field": "email",
|
|
278
|
+
children: /* @__PURE__ */ r(
|
|
279
|
+
ks,
|
|
280
|
+
{
|
|
281
|
+
ref: Z.ref,
|
|
282
|
+
name: "",
|
|
283
|
+
readOnly: !0,
|
|
284
|
+
autoComplete: "username",
|
|
285
|
+
dir: "ltr",
|
|
286
|
+
disableBuiltInValidation: !0,
|
|
287
|
+
onChange: Z.quiet()
|
|
288
|
+
}
|
|
289
|
+
)
|
|
290
|
+
}
|
|
291
|
+
) : null,
|
|
292
|
+
/* @__PURE__ */ r(
|
|
293
|
+
L,
|
|
294
|
+
{
|
|
295
|
+
id: k,
|
|
296
|
+
label: ls.password,
|
|
297
|
+
required: !0,
|
|
298
|
+
error: v("password"),
|
|
299
|
+
announceError: !d.lists("password"),
|
|
300
|
+
"data-field": "password",
|
|
301
|
+
children: /* @__PURE__ */ r(
|
|
302
|
+
us,
|
|
303
|
+
{
|
|
304
|
+
ref: Q.password,
|
|
305
|
+
name: ts("password"),
|
|
306
|
+
autoComplete: "new-password",
|
|
307
|
+
requirements: Y,
|
|
308
|
+
value: t.password,
|
|
309
|
+
onChange: (s) => $("password", s.target.value),
|
|
310
|
+
onBlur: () => G("password")
|
|
311
|
+
}
|
|
312
|
+
)
|
|
313
|
+
}
|
|
314
|
+
),
|
|
315
|
+
/* @__PURE__ */ r(
|
|
316
|
+
L,
|
|
317
|
+
{
|
|
318
|
+
id: V,
|
|
319
|
+
label: ls.passwordConfirm,
|
|
320
|
+
required: !0,
|
|
321
|
+
error: v("passwordConfirm"),
|
|
322
|
+
announceError: !d.lists("passwordConfirm"),
|
|
323
|
+
"data-field": "passwordConfirm",
|
|
324
|
+
children: /* @__PURE__ */ r(
|
|
325
|
+
us,
|
|
326
|
+
{
|
|
327
|
+
ref: Q.passwordConfirm,
|
|
328
|
+
name: ts("passwordConfirm"),
|
|
329
|
+
autoComplete: "new-password",
|
|
330
|
+
value: t.passwordConfirm,
|
|
331
|
+
onChange: (s) => $("passwordConfirm", s.target.value),
|
|
332
|
+
onBlur: () => {
|
|
333
|
+
G("passwordConfirm"), A.confirmProps.onBlur();
|
|
334
|
+
}
|
|
335
|
+
}
|
|
336
|
+
)
|
|
337
|
+
}
|
|
338
|
+
),
|
|
339
|
+
/* @__PURE__ */ r(Js, { fields: Ds }),
|
|
340
|
+
/* @__PURE__ */ r(
|
|
341
|
+
D,
|
|
342
|
+
{
|
|
343
|
+
type: "submit",
|
|
344
|
+
intent: "primary",
|
|
345
|
+
size: "lg",
|
|
346
|
+
loading: q,
|
|
347
|
+
className: "ds:w-full",
|
|
348
|
+
"data-action": "submit",
|
|
349
|
+
children: bs ?? o("resetPasswordForm.submit")
|
|
350
|
+
}
|
|
351
|
+
)
|
|
352
|
+
]
|
|
353
|
+
}
|
|
354
|
+
),
|
|
355
|
+
/* @__PURE__ */ r(Ks, { busy: q })
|
|
356
|
+
] })
|
|
357
|
+
] }) })
|
|
358
|
+
}
|
|
359
|
+
);
|
|
360
|
+
}
|
|
361
|
+
);
|
|
362
|
+
nr.displayName = "ResetPasswordForm";
|
|
363
|
+
export {
|
|
364
|
+
b as R,
|
|
365
|
+
nr as a
|
|
366
|
+
};
|
|
367
|
+
//# sourceMappingURL=reset-password-form-Cf9QPEJu.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"reset-password-form-Cf9QPEJu.js","sources":["../../src/patterns/_shared/password-policy.ts","../../src/patterns/reset-password-form/reset-password-form.tsx"],"sourcesContent":["/* -------------------------------------------------------------------- */\n/* The platform's password rule, as the live checklist shows it. */\n/* */\n/* The platform's rule is written in ASCII (`[A-Z]`, `[a-z]`, `\\d`), so */\n/* the checklist counts the same characters and never shows green for a */\n/* password the server will refuse. Shipped with the patterns that */\n/* import it; not an export of its own. */\n/* -------------------------------------------------------------------- */\n\nimport type { UsePasswordRequirementsOptions } from '../../components/password-input';\n\nexport const PLATFORM_PASSWORD_POLICY: UsePasswordRequirementsOptions = {\n minLength: 12,\n uppercase: true,\n lowercase: true,\n digit: true,\n charset: 'ascii',\n};\n","/* -------------------------------------------------------------------- */\n/* ResetPasswordForm — the card the reset email opens, where the person */\n/* chooses a new password. */\n/* */\n/* Two password fields with the live rules checklist, then one of two */\n/* results in place of the form: the password has changed, or the link */\n/* has expired. The host checks the link and the code, sets the state */\n/* and owns every server rule; the card checks what a browser can check, */\n/* then hands the values to `onSubmit` or posts a real form. A password */\n/* is never put in an attribute. */\n/* -------------------------------------------------------------------- */\n\nimport {\n forwardRef,\n useEffect,\n useId,\n useMemo,\n useRef,\n useState,\n type HTMLAttributes,\n type ReactNode,\n} from 'react';\nimport { useTranslation } from 'react-i18next';\nimport { cva } from 'class-variance-authority';\nimport { Alert } from '../../components/alert';\nimport { Button } from '../../components/button';\nimport { Card } from '../../components/card';\nimport { EmailInput } from '../../components/email-input';\nimport { ErrorSummary } from '../../components/error-summary';\nimport { FormField } from '../../components/form-field';\nimport {\n PasswordInput,\n usePasswordRequirements,\n} from '../../components/password-input';\nimport { isSafeHref } from '../../components/_shared/safe-href';\nimport { useStateBackedInput } from '../../components/_shared/use-state-backed-input';\nimport { useFieldMatch } from '../../hooks/use-field-match';\nimport {\n AuthCardHeading,\n AuthFormMessage,\n AuthFormStatus,\n ExtraFields,\n useExtraFields,\n useFormAction,\n} from '../_shared/auth-form-parts';\nimport type { BrandMarkMotion } from '../_shared/brand-mark';\nimport { PLATFORM_PASSWORD_POLICY } from '../_shared/password-policy';\nimport {\n useErrorSummary,\n useFormMessageAnnounce,\n} from '../_shared/use-error-summary';\nimport { useRegistrationSubmit } from '../registration-form/use-registration-submit';\n\n/* -------------------------------------------------------------------- */\n/* Types */\n/* -------------------------------------------------------------------- */\n\n/** The form's two fields. */\nexport const RESET_PASSWORD_FORM_FIELDS = [\n 'password',\n 'passwordConfirm',\n] as const;\n\nexport type ResetPasswordFormField =\n (typeof RESET_PASSWORD_FORM_FIELDS)[number];\n\n/** What the card shows: the form, the result after a good change, or the\n * result for a link that no longer works. */\nexport type ResetPasswordFormState = 'form' | 'done' | 'expired';\n\n/** What `onSubmit` receives once both passwords have passed their checks. */\nexport interface ResetPasswordFormValues {\n password: string;\n passwordConfirm: string;\n}\n\n/** Messages from the server, already translated: one for each field, plus\n * `form` for a message about the whole form. */\nexport type ResetPasswordFormErrors = Partial<\n Record<ResetPasswordFormField | 'form', string>\n>;\n\n/** The host's own form field names, for a native form post. They are\n * needed: a field without a name is not posted. */\nexport type ResetPasswordFormFieldNames = Record<\n ResetPasswordFormField,\n string\n>;\n\nexport interface ResetPasswordFormProps extends Omit<\n HTMLAttributes<HTMLDivElement>,\n 'title' | 'onSubmit'\n> {\n /**\n * What the card shows. Default `form`. `done` and `expired` replace the\n * form and take focus when they appear.\n */\n state?: ResetPasswordFormState;\n /** Replaces the form's heading \"Choose a new password\". Pass it\n * translated. The result states have their own heading. */\n title?: string;\n /** Replaces the line under the form's heading (\"Enter a new password\n * for your account.\"). Pass it translated. */\n description?: string;\n /**\n * The heading's level. Default 1: this page usually has no other\n * heading. Pass 2 on a page that has its own `h1`.\n */\n headingLevel?: 1 | 2 | 3;\n /** Shows the Alfadocs mark above the heading. Default true. */\n showLogo?: boolean;\n /** How the mark arrives when the card opens. Default `assemble`. */\n logoMotion?: BrandMarkMotion;\n /**\n * Host content between the heading and the fields, such as a notice. It\n * sits outside the form, so nothing in it is posted.\n */\n children?: ReactNode;\n /**\n * The address the password is for. In the form it shows read-only, and\n * is the username a password manager saves the new password under. In\n * the `done` state it is named in the line under the result.\n */\n email?: string;\n /**\n * The `done` state's action, \"Sign in\". A path on the same site, or an\n * address written in full. Anything else shows no button.\n */\n loginHref?: string;\n /**\n * The `expired` state's action, \"Ask for a new link\". A path on the\n * same site, or an address written in full. Anything else shows no\n * button.\n */\n requestHref?: string;\n /**\n * Messages from the server, already translated. A field's message shows\n * on the field until the user changes it; `form` shows above the\n * fields. When messages arrive, focus moves to the error summary when a\n * field has one, or to the message above the fields when only that\n * says something. Passwords the server refused are emptied.\n */\n errors?: ResetPasswordFormErrors;\n /** Replaces the button's \"Change password\". Pass it translated. */\n submitLabel?: string;\n /**\n * True while the host sends the passwords: the button shows a spinner\n * and a second submit is ignored. Set it inside `onSubmit`, before\n * anything is awaited.\n */\n submitting?: boolean;\n /** For React hosts: called with both passwords once they have passed\n * their checks. Not called when `fieldNames` is set. */\n onSubmit?: (values: ResetPasswordFormValues) => void;\n /**\n * For a native form post: the host's own field names, e.g.\n * `{ password: 'lost_password_reset[password1]', passwordConfirm:\n * 'lost_password_reset[password2]' }`. When set, the inputs carry those\n * names and the browser posts the form.\n */\n fieldNames?: ResetPasswordFormFieldNames;\n /**\n * Where a native form post goes. Default: the current address. Only a\n * path, or an address on the page's own origin, is accepted: another\n * origin is never sent what the user typed. Does nothing without\n * `fieldNames`.\n */\n action?: string;\n /**\n * Extra hidden inputs posted with a native form, by name: a CSRF token,\n * e.g. `{ 'lost_password_reset[_token]': token }`. Not used with\n * `onSubmit`. A name that is also in `fieldNames` is left out.\n */\n hiddenFields?: Readonly<Record<string, string>>;\n}\n\n/* -------------------------------------------------------------------- */\n/* Styles */\n/* -------------------------------------------------------------------- */\n\n// 400px at most, in px: a host whose root font size is not 16px would\n// stretch or squeeze a width in rem.\nconst resetPasswordFormVariants = cva(\n 'ds:mx-auto ds:w-full ds:max-w-[400px] ds:text-start ds:text-[var(--foreground)]',\n);\n\n// The result takes focus when it appears, so it shows a ring.\nconst resultVariants = cva(\n 'ds:focus-visible:outline-solid ds:focus-visible:outline-[length:var(--focus-ring-width)] ds:focus-visible:outline-[var(--ring)] ds:focus-visible:outline-offset-[length:var(--focus-ring-offset)] ds:forced-colors:focus-visible:outline-[CanvasText]',\n);\n\n/* -------------------------------------------------------------------- */\n/* Helpers */\n/* -------------------------------------------------------------------- */\n\ntype FocusTarget = ResetPasswordFormField | 'form';\n\n/** Unicode isolates: they keep an address's order inside any sentence. */\nconst LTR_ISOLATE = '\\u2066';\nconst POP_ISOLATE = '\\u2069';\n\n/** The result's heading, by the level of the card's own. */\nconst RESULT_HEADING = { 1: 'h2', 2: 'h3', 3: 'h4' } as const;\n\nconst hasMessage = (errors: ResetPasswordFormErrors): boolean =>\n Object.values(errors).some(Boolean);\n\nconst focusTargetFor = (\n messages: ResetPasswordFormErrors,\n): FocusTarget | undefined =>\n RESET_PASSWORD_FORM_FIELDS.find((field) => messages[field]) ??\n (messages.form ? 'form' : undefined);\n\n/* -------------------------------------------------------------------- */\n/* Component */\n/* -------------------------------------------------------------------- */\n\n/**\n * The card for the page the reset email opens. Mount it on the\n * reset-password page, inside `SignedOutFrame` or the host's own chrome.\n */\nexport const ResetPasswordForm = forwardRef<\n HTMLDivElement,\n ResetPasswordFormProps\n>(\n (\n {\n state = 'form',\n title,\n description,\n headingLevel = 1,\n showLogo = true,\n logoMotion = 'assemble',\n children,\n email,\n loginHref,\n requestHref,\n errors,\n submitLabel,\n submitting = false,\n onSubmit,\n fieldNames,\n action,\n hiddenFields,\n className,\n ...rest\n },\n ref,\n ) => {\n const { t } = useTranslation('ui');\n const titleId = useId();\n const resultTitleId = useId();\n const resultDescriptionId = useId();\n const emailFieldId = useId();\n const passwordFieldId = useId();\n const passwordConfirmFieldId = useId();\n const formMessageId = useId();\n const native = fieldNames !== undefined;\n const fieldIds: Record<ResetPasswordFormField, string> = {\n password: passwordFieldId,\n passwordConfirm: passwordConfirmFieldId,\n };\n\n /* ------------------------------ State ----------------------------- */\n\n // Passwords always start empty and are held in state only: the inputs\n // get them as a DOM property, never as an attribute.\n const [values, setValues] = useState<ResetPasswordFormValues>({\n password: '',\n passwordConfirm: '',\n });\n const [touched, setTouched] = useState<\n Partial<Record<ResetPasswordFormField, boolean>>\n >({});\n const [submitted, setSubmitted] = useState(false);\n const [serverErrors, setServerErrors] = useState<ResetPasswordFormErrors>(\n () => errors ?? {},\n );\n\n const set = (field: ResetPasswordFormField, value: string) => {\n setValues((previous) => ({ ...previous, [field]: value }));\n // The server's message was about the old value.\n setServerErrors((previous) =>\n previous[field] ? { ...previous, [field]: undefined } : previous,\n );\n };\n const leave = (field: ResetPasswordFormField) =>\n setTouched((previous) =>\n previous[field] ? previous : { ...previous, [field]: true },\n );\n const emptyPasswords = () => {\n setValues({ password: '', passwordConfirm: '' });\n setTouched({});\n };\n\n /* ---------------------------- Validation -------------------------- */\n\n const requirements = usePasswordRequirements(PLATFORM_PASSWORD_POLICY);\n const match = useFieldMatch({\n value: values.password,\n confirmValue: values.passwordConfirm,\n kind: 'password',\n submitted,\n });\n\n /** What stops a submit, whether or not the message shows yet. */\n const invalid: Record<ResetPasswordFormField, boolean> = {\n password:\n values.password === '' ||\n !requirements.every((rule) => rule.test(values.password)),\n passwordConfirm: values.passwordConfirm === '' || !match.matches,\n };\n // A message shows once the user has left the field or tried to submit.\n const due = (field: ResetPasswordFormField) =>\n submitted || touched[field] === true;\n const ownErrors: Record<ResetPasswordFormField, string | undefined> = {\n password:\n due('password') && invalid.password\n ? values.password === ''\n ? t('resetPasswordForm.passwordRequired')\n : t('resetPasswordForm.passwordInvalid')\n : undefined,\n passwordConfirm:\n values.passwordConfirm === ''\n ? due('passwordConfirm')\n ? t('resetPasswordForm.passwordConfirmRequired')\n : undefined\n : match.error,\n };\n const errorFor = (field: ResetPasswordFormField) =>\n serverErrors[field] ?? ownErrors[field];\n\n /* ------------------------------ Focus ----------------------------- */\n\n const controls = useRef<\n Partial<Record<ResetPasswordFormField, HTMLElement | null>>\n >({});\n const control = useMemo(\n () => ({\n password: (node: HTMLElement | null) => {\n controls.current.password = node;\n },\n passwordConfirm: (node: HTMLElement | null) => {\n controls.current.passwordConfirm = node;\n },\n }),\n [],\n );\n const formMessage = useRef<HTMLDivElement>(null);\n const result = useRef<HTMLDivElement>(null);\n\n // The address stays out of the input's `value` attribute, where a\n // copied outerHTML or a session replay could read it.\n const emailInput = useRef<HTMLInputElement>(null);\n const emailField = useStateBackedInput(email ?? '', emailInput);\n\n // Every field with a message after a refused submit, or after a server\n // answer, is listed at the top of the form, and focus goes there. A\n // page the server rendered after a failed post opens that way too.\n const [openedWithFieldMessage] = useState(() =>\n RESET_PASSWORD_FORM_FIELDS.some((field) => Boolean(errors?.[field])),\n );\n const summary = useErrorSummary(\n RESET_PASSWORD_FORM_FIELDS,\n errorFor,\n openedWithFieldMessage,\n );\n const formMessageAnnounce = useFormMessageAnnounce(\n serverErrors.form,\n summary.listed.length > 0,\n );\n\n // A new object for each request, so asking twice for the same place\n // moves focus twice.\n const [focusRequest, setFocusRequest] = useState<{\n target: FocusTarget;\n } | null>(() => {\n const target = openedWithFieldMessage\n ? undefined\n : focusTargetFor(errors ?? {});\n return target ? { target } : null;\n });\n useEffect(() => {\n if (!focusRequest) return;\n if (focusRequest.target === 'form') formMessage.current?.focus();\n else controls.current[focusRequest.target]?.focus();\n }, [focusRequest]);\n\n // The form, and the button that had focus, are gone once a result\n // shows. Move focus to it. Not on a page that opens on a result: that\n // one is read from the top like any other.\n // A password does not wait in memory behind a result.\n const clearOnResult = state !== 'form';\n useEffect(() => {\n if (clearOnResult) {\n setValues({ password: '', passwordConfirm: '' });\n setTouched({});\n }\n }, [clearOnResult]);\n const wasForm = useRef(state === 'form');\n useEffect(() => {\n if (state !== 'form' && wasForm.current) result.current?.focus();\n wasForm.current = state === 'form';\n }, [state]);\n\n /* ------------------------------ Submit ---------------------------- */\n\n const submit = useRegistrationSubmit<ResetPasswordFormField>({\n errors,\n submitting,\n native,\n captcha: false,\n firstProblem: () =>\n RESET_PASSWORD_FORM_FIELDS.find((field) => invalid[field]),\n onRefused: (field) => {\n setSubmitted(true);\n summary.open(() => setFocusRequest({ target: field }));\n },\n // Only a React host gets here: a native post is the browser's own.\n deliver: () =>\n onSubmit?.({\n password: values.password,\n passwordConfirm: values.passwordConfirm,\n }),\n onAnswer: (answer) => {\n const next: ResetPasswordFormErrors = answer;\n setServerErrors(next);\n if (!hasMessage(next)) return;\n // Never keep a password the server did not accept.\n emptyPasswords();\n setSubmitted(false);\n summary.open(() => {\n const target = focusTargetFor(next);\n if (target) setFocusRequest({ target });\n });\n },\n // The page came back from the browser's cache as it was left: the\n // passwords must not come back with it.\n onRestore: emptyPasswords,\n });\n const { busy } = submit;\n\n /* ------------------------------ Render ---------------------------- */\n\n const formAction = useFormAction('ResetPasswordForm', native, action);\n const extraFields = useExtraFields(\n 'ResetPasswordForm',\n native,\n fieldNames,\n hiddenFields,\n );\n const name = (field: ResetPasswordFormField) =>\n native ? fieldNames[field] : field;\n const safe = (href: string | undefined) =>\n href && isSafeHref(href) ? href : undefined;\n const loginLink = safe(loginHref);\n const requestLink = safe(requestHref);\n const showingForm = state === 'form';\n const labels: Record<ResetPasswordFormField, string> = {\n password: t('resetPasswordForm.password'),\n passwordConfirm: t('resetPasswordForm.passwordConfirm'),\n };\n const resultHeading = RESULT_HEADING[headingLevel];\n\n return (\n <div\n ref={ref}\n {...rest}\n data-component=\"reset-password-form\"\n data-state={state}\n className={resetPasswordFormVariants({ className })}\n >\n <Card variant=\"elevated\">\n <Card.Body className=\"ds:flex ds:flex-col ds:gap-[var(--spacing-lg)]\">\n <AuthCardHeading\n id={titleId}\n title={\n showingForm\n ? (title ?? t('resetPasswordForm.title'))\n : t('resetPasswordForm.pageTitle')\n }\n description={\n showingForm\n ? (description ?? t('resetPasswordForm.description'))\n : undefined\n }\n level={headingLevel}\n showLogo={showLogo}\n logoMotion={logoMotion}\n />\n\n {children ? (\n <div\n data-slot=\"host-content\"\n className=\"ds:flex ds:flex-col ds:gap-[var(--spacing-md)]\"\n >\n {children}\n </div>\n ) : null}\n\n {state === 'done' && (\n <>\n <Alert\n ref={result}\n variant=\"success\"\n tabIndex={-1}\n aria-labelledby={resultTitleId}\n aria-describedby={resultDescriptionId}\n data-slot=\"result\"\n className={resultVariants()}\n >\n <Alert.Title id={resultTitleId} as={resultHeading}>\n {t('resetPasswordForm.doneTitle')}\n </Alert.Title>\n <Alert.Description id={resultDescriptionId}>\n {email\n ? t('resetPasswordForm.doneDescriptionEmail', {\n // Isolated left to right, so the address keeps its\n // order inside a right-to-left sentence.\n email: `${LTR_ISOLATE}${email}${POP_ISOLATE}`,\n })\n : t('resetPasswordForm.doneDescription')}\n </Alert.Description>\n </Alert>\n {loginLink && (\n <Button\n asChild\n intent=\"primary\"\n size=\"lg\"\n className=\"ds:w-full\"\n >\n <a href={loginLink} data-action=\"login\">\n {t('resetPasswordForm.signIn')}\n </a>\n </Button>\n )}\n </>\n )}\n\n {state === 'expired' && (\n <>\n <Alert\n ref={result}\n variant=\"warning\"\n // Focus moves here: an assertive alert as well would read\n // it twice, and over a page that opens on it.\n announce=\"polite\"\n tabIndex={-1}\n aria-labelledby={resultTitleId}\n aria-describedby={resultDescriptionId}\n data-slot=\"result\"\n className={resultVariants()}\n >\n <Alert.Title id={resultTitleId} as={resultHeading}>\n {t('resetPasswordForm.expiredTitle')}\n </Alert.Title>\n <Alert.Description id={resultDescriptionId}>\n {t('resetPasswordForm.expiredDescription')}\n </Alert.Description>\n </Alert>\n {requestLink && (\n <Button\n asChild\n intent=\"primary\"\n size=\"lg\"\n className=\"ds:w-full\"\n >\n <a href={requestLink} data-action=\"request-link\">\n {t('resetPasswordForm.requestLink')}\n </a>\n </Button>\n )}\n </>\n )}\n\n {showingForm && (\n <>\n <form\n noValidate\n method=\"post\"\n action={formAction}\n aria-labelledby={titleId}\n aria-busy={busy || undefined}\n onSubmit={submit.handleSubmit}\n className=\"ds:flex ds:flex-col ds:gap-[var(--spacing-md)]\"\n >\n <ErrorSummary\n ref={summary.ref}\n headingLevel={(headingLevel + 1) as 2 | 3 | 4}\n // The message about the whole form is read with it.\n aria-describedby={\n serverErrors.form ? formMessageId : undefined\n }\n errors={summary.listed.map((field) => ({\n field,\n message: errorFor(field) ?? '',\n targetId: fieldIds[field],\n }))}\n />\n\n {serverErrors.form && (\n <AuthFormMessage\n ref={formMessage}\n id={formMessageId}\n announce={formMessageAnnounce}\n >\n {serverErrors.form}\n </AuthFormMessage>\n )}\n\n {email ? (\n <FormField\n id={emailFieldId}\n label={t('resetPasswordForm.email')}\n data-field=\"email\"\n >\n {/* Read-only, and not posted: it has no name. `username`\n is what password managers pair with\n `new-password`, so the new password is saved under\n this address. */}\n <EmailInput\n ref={emailField.ref}\n name=\"\"\n readOnly\n autoComplete=\"username\"\n // An address reads left to right in any language.\n dir=\"ltr\"\n disableBuiltInValidation\n onChange={emailField.quiet()}\n />\n </FormField>\n ) : null}\n\n <FormField\n id={passwordFieldId}\n label={labels.password}\n required\n error={errorFor('password')}\n announceError={!summary.lists('password')}\n data-field=\"password\"\n >\n {/* PasswordInput names itself \"password\" when given no\n name; an empty one keeps a field out of the post. */}\n <PasswordInput\n ref={control.password}\n name={name('password')}\n autoComplete=\"new-password\"\n requirements={requirements}\n value={values.password}\n onChange={(event) => set('password', event.target.value)}\n onBlur={() => leave('password')}\n />\n </FormField>\n\n <FormField\n id={passwordConfirmFieldId}\n label={labels.passwordConfirm}\n required\n error={errorFor('passwordConfirm')}\n announceError={!summary.lists('passwordConfirm')}\n data-field=\"passwordConfirm\"\n >\n <PasswordInput\n ref={control.passwordConfirm}\n name={name('passwordConfirm')}\n autoComplete=\"new-password\"\n value={values.passwordConfirm}\n onChange={(event) =>\n set('passwordConfirm', event.target.value)\n }\n onBlur={() => {\n leave('passwordConfirm');\n match.confirmProps.onBlur();\n }}\n />\n </FormField>\n\n <ExtraFields fields={extraFields} />\n\n <Button\n type=\"submit\"\n intent=\"primary\"\n size=\"lg\"\n loading={busy}\n className=\"ds:w-full\"\n data-action=\"submit\"\n >\n {submitLabel ?? t('resetPasswordForm.submit')}\n </Button>\n </form>\n {/* Outside the form: a screen reader may hold back what\n changes inside a busy region. */}\n <AuthFormStatus busy={busy} />\n </>\n )}\n </Card.Body>\n </Card>\n </div>\n );\n },\n);\nResetPasswordForm.displayName = 'ResetPasswordForm';\n"],"names":["PLATFORM_PASSWORD_POLICY","RESET_PASSWORD_FORM_FIELDS","resetPasswordFormVariants","cva","resultVariants","LTR_ISOLATE","POP_ISOLATE","RESULT_HEADING","hasMessage","errors","focusTargetFor","messages","field","ResetPasswordForm","forwardRef","state","title","description","headingLevel","showLogo","logoMotion","children","email","loginHref","requestHref","submitLabel","submitting","onSubmit","fieldNames","action","hiddenFields","className","rest","ref","t","useTranslation","titleId","useId","resultTitleId","resultDescriptionId","emailFieldId","passwordFieldId","passwordConfirmFieldId","formMessageId","native","fieldIds","values","setValues","useState","touched","setTouched","submitted","setSubmitted","serverErrors","setServerErrors","set","value","previous","leave","emptyPasswords","requirements","usePasswordRequirements","match","useFieldMatch","invalid","rule","due","ownErrors","errorFor","controls","useRef","control","useMemo","node","formMessage","result","emailInput","emailField","useStateBackedInput","openedWithFieldMessage","summary","useErrorSummary","formMessageAnnounce","useFormMessageAnnounce","focusRequest","setFocusRequest","target","useEffect","_a","_b","clearOnResult","wasForm","submit","useRegistrationSubmit","answer","next","busy","formAction","useFormAction","extraFields","useExtraFields","name","safe","href","isSafeHref","loginLink","requestLink","showingForm","labels","resultHeading","jsx","Card","AuthCardHeading","jsxs","Fragment","Alert","Button","ErrorSummary","AuthFormMessage","FormField","EmailInput","PasswordInput","event","ExtraFields","AuthFormStatus"],"mappings":";;;;;;;;;;;;;;;;;AAWO,MAAMA,KAA2D;AAAA,EACtE,WAAW;AAAA,EACX,WAAW;A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AA,0BAE3C,QAAQ,MAAM;AACZ,4BAAAhE,EAAM,iBAAiB,GACvBI,EAAM,aAAa,OAAA;AAAA,0BACrB;AAAA,wBAAA;AAAA,sBAAA;AAAA,oBACF;AAAA,kBAAA;AAAA,kBAGF,gBAAAgD,EAACa,IAAA,EAAY,QAAQxB,GAAA,CAAa;AAAA,kBAElC,gBAAAW;AAAA,oBAACM;AAAA,oBAAA;AAAA,sBACC,MAAK;AAAA,sBACL,QAAO;AAAA,sBACP,MAAK;AAAA,sBACL,SAASpB;AAAA,sBACT,WAAU;AAAA,sBACV,eAAY;AAAA,sBAEX,UAAAvE,MAAeS,EAAE,0BAA0B;AAAA,oBAAA;AAAA,kBAAA;AAAA,gBAC9C;AAAA,cAAA;AAAA,YAAA;AAAA,YAIF,gBAAA4E,EAACc,MAAe,MAAA5B,EAAA,CAAY;AAAA,UAAA,EAAA,CAC9B;AAAA,QAAA,EAAA,CAEJ,EAAA,CACF;AAAA,MAAA;AAAA,IAAA;AAAA,EAGN;AACF;AACAnF,GAAkB,cAAc;"}
|
|
@@ -9,7 +9,7 @@ import { B as he } from "./button-DohK_Ak_.js";
|
|
|
9
9
|
import { C as B } from "./card-BA4Ig_kn.js";
|
|
10
10
|
import { D as Ze } from "./date-picker-CdhXlgVI.js";
|
|
11
11
|
import { E as Ve } from "./error-summary-mGxIyDAY.js";
|
|
12
|
-
import { F } from "./form-field-
|
|
12
|
+
import { F } from "./form-field-CyHfOVKF.js";
|
|
13
13
|
import { P as ue } from "./phone-input-C3NrD-nl.js";
|
|
14
14
|
import { a as en, i as nn } from "./safe-href-5dbsfbQn.js";
|
|
15
15
|
import { u as ge } from "./use-state-backed-input-DhRQo6gM.js";
|
|
@@ -406,4 +406,4 @@ export {
|
|
|
406
406
|
q as S,
|
|
407
407
|
fn as a
|
|
408
408
|
};
|
|
409
|
-
//# sourceMappingURL=send-registration-link-form-
|
|
409
|
+
//# sourceMappingURL=send-registration-link-form-vTn1HxjA.js.map
|