/* password-field.jsx — PasswordField + StrengthMeter (the `.pw` composite), shared by the auth * screens (auth-app.jsx) and the account menu's change-password dialog (account-menu.jsx). * Moved out of auth-app.jsx 2026-09-20, markup unchanged (the error line's class is now * `pw-err`). Wrapped in an IIFE: planner scripts share one global scope, so a top-level const * here would collide with the host page's own. Needs window.__AUTH (auth-helpers.js) for * pwRules/meterTone and password-field.css. Exports window.RadishPassword. */ (function () { const { useState, useId } = React; const REQS = [["len", "10+ characters"], ["digit", "A number"], ["symbol", "A symbol"]]; function StrengthMeter({ password }) { const A = window.__AUTH; const rules = A.pwRules(password); const tone = A.meterTone(rules.score); return ( <>