هل تعلم؟dyk.si

التحقق الفوري Inline Validation

علامة صح خضراء أو رسالة حمراء تظهر بجانب الحقل أثناء تعبئته، قبل إرسال النموذج.

aria-invalid + aria-describedby

متى تستخدمه

للحقول التي لها شروط: البريد الإلكتروني، أو كلمة السر، أو اسم المستخدم.

خطأ شائع

لا تُظهر خطأ قبل أن ينهي المستخدم الكتابة.

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

Validate on blur, not on every keystroke, and never rely on color alone.

اسمه في الكود

HTML/CSSaria-invalid + aria-describedby
Reactreact-hook-form errors
Jetpack ComposeOutlinedTextField(isError, supportingText)
SwiftUI.onChange + Text (custom)

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

Add a Inline Validation to this screen. What it is: A green check or red message beside a field as you fill it, before you submit. Implement with: aria-invalid + aria-describedby (HTML/CSS). Accessibility: Validate on blur, not on every keystroke, and never rely on color alone. When to use it: For fields with rules: email, password, username. Avoid: Don’t show an error before the user finishes typing. Reuse the project's existing design tokens, spacing and component conventions.

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

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