Spaces:
Running on CPU Upgrade
Running on CPU Upgrade
Update frontend/src/pages/Login.jsx
Browse files- frontend/src/pages/Login.jsx +28 -20
frontend/src/pages/Login.jsx
CHANGED
|
@@ -141,27 +141,35 @@ export const Login = () => {
|
|
| 141 |
</button>
|
| 142 |
</div>
|
| 143 |
|
| 144 |
-
{/* Password Validation Checklist */}
|
| 145 |
-
|
| 146 |
-
<div className=
|
| 147 |
-
<
|
| 148 |
-
|
| 149 |
-
|
| 150 |
-
|
| 151 |
-
|
| 152 |
-
|
| 153 |
-
<
|
| 154 |
-
|
| 155 |
-
|
| 156 |
-
|
| 157 |
-
|
| 158 |
-
|
| 159 |
-
<
|
| 160 |
-
|
| 161 |
-
|
| 162 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 163 |
</div>
|
| 164 |
-
|
| 165 |
</div>
|
| 166 |
|
| 167 |
<div className="flex items-center gap-3 mt-1">
|
|
|
|
| 141 |
</button>
|
| 142 |
</div>
|
| 143 |
|
| 144 |
+
{/* Password Validation Checklist - Only shown when typing password */}
|
| 145 |
+
{password.length > 0 && (
|
| 146 |
+
<div className="flex flex-col gap-1.5 mt-2 p-3 bg-slate-50 border border-slate-200 rounded-xl text-xs animate-fade-in">
|
| 147 |
+
<div className={`flex items-center gap-2 font-medium transition-colors ${password.length >= 8 ? 'text-emerald-600 font-semibold' : 'text-slate-500'}`}>
|
| 148 |
+
<span className="material-symbols-outlined text-[16px]">
|
| 149 |
+
{password.length >= 8 ? 'check_circle' : 'radio_button_unchecked'}
|
| 150 |
+
</span>
|
| 151 |
+
<span>At least 8 characters</span>
|
| 152 |
+
</div>
|
| 153 |
+
<div className={`flex items-center gap-2 font-medium transition-colors ${/[A-Z]/.test(password) ? 'text-emerald-600 font-semibold' : 'text-slate-500'}`}>
|
| 154 |
+
<span className="material-symbols-outlined text-[16px]">
|
| 155 |
+
{/[A-Z]/.test(password) ? 'check_circle' : 'radio_button_unchecked'}
|
| 156 |
+
</span>
|
| 157 |
+
<span>One uppercase letter</span>
|
| 158 |
+
</div>
|
| 159 |
+
<div className={`flex items-center gap-2 font-medium transition-colors ${/[a-z]/.test(password) ? 'text-emerald-600 font-semibold' : 'text-slate-500'}`}>
|
| 160 |
+
<span className="material-symbols-outlined text-[16px]">
|
| 161 |
+
{/[a-z]/.test(password) ? 'check_circle' : 'radio_button_unchecked'}
|
| 162 |
+
</span>
|
| 163 |
+
<span>One lowercase letter</span>
|
| 164 |
+
</div>
|
| 165 |
+
<div className={`flex items-center gap-2 font-medium transition-colors ${/[^A-Za-z0-9]/.test(password) ? 'text-emerald-600 font-semibold' : 'text-slate-500'}`}>
|
| 166 |
+
<span className="material-symbols-outlined text-[16px]">
|
| 167 |
+
{/[^A-Za-z0-9]/.test(password) ? 'check_circle' : 'radio_button_unchecked'}
|
| 168 |
+
</span>
|
| 169 |
+
<span>One special character</span>
|
| 170 |
+
</div>
|
| 171 |
</div>
|
| 172 |
+
)}
|
| 173 |
</div>
|
| 174 |
|
| 175 |
<div className="flex items-center gap-3 mt-1">
|