Skip to content

Refactor: Standardize error styling across Auth and Task forms#1205

Open
Abhishek2005-ard wants to merge 5 commits into
aryandas2911:mainfrom
Abhishek2005-ard:ui/standardize-form-errors
Open

Refactor: Standardize error styling across Auth and Task forms#1205
Abhishek2005-ard wants to merge 5 commits into
aryandas2911:mainfrom
Abhishek2005-ard:ui/standardize-form-errors

Conversation

@Abhishek2005-ard
Copy link
Copy Markdown
Contributor

Description

This PR resolves the inconsistency in how authentication and database errors were displayed across the application. Previously, the Login, Signup, and Task Creation forms used different inline HTML/Tailwind classes to show errors, resulting in varying text colors, paddings, and missing accessibility roles.

Changes Made

  • Created FormError Component: Added a new, reusable <FormError /> component in frontend/src/components/common/FormError.jsx.
  • Consistent Styling: Enforced a uniform aesthetic using a soft red background (bg-red-50), red borders, a lucide-react warning icon (AlertCircle), and proper spacing.
  • Accessibility: Added role="alert" to the error container so screen readers instantly announce form validation failures.
  • Integration: Replaced all hardcoded error divs with the new <FormError /> component inside Login.jsx, Signup.jsx, and TaskFormModal.jsx.

Type of Change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Refactor / UI Improvement (improves code structure or UI consistency without adding new features)

close #1189

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[UI/UX] Standardize form validation error message UI across all pages

1 participant