هل تعلم؟dyk.si

إظهار كلمة السر Password Visibility Toggle

أيقونة العين داخل حقل كلمة السر؛ عند النقر عليها تظهر الحروف بدل النقاط.

<input type="password"> + toggle button

متى تستخدمه

في كل حقل كلمة سر، خصوصاً على الهاتف.

خطأ شائع

لا تمنع اللصق في حقل كلمة السر.

إمكانية الوصول

Label the button (Show password) and reflect state with aria-pressed.

اسمه في الكود

HTML/CSS<input type="password"> + toggle button
React<PasswordInput>
Jetpack ComposePasswordVisualTransformation + IconButton
SwiftUISecureField / TextField swap

برومبت جاهز لوكيل البرمجة

Add a Password Visibility Toggle to this screen. What it is: The eye icon inside a password field that reveals the characters instead of dots. Implement with: <input type="password"> + toggle button (HTML/CSS). Accessibility: Label the button (Show password) and reflect state with aria-pressed. When to use it: On every password field, especially on mobile. Avoid: Don’t block paste in password fields. Reuse the project's existing design tokens, spacing and component conventions.

أو ركّب صفحة كاملة من هذا العنصر وغيره →

البرومبت بالإنجليزية لأنها الأدق مع Claude Code وأمثاله.