Skip to content

feat: enhance duplicate prototype name error handling with UX improvements#333

Merged
NhanLuongBGSV merged 5 commits intoeclipse-autowrx:mainfrom
SangNT12:main
Mar 6, 2026
Merged

feat: enhance duplicate prototype name error handling with UX improvements#333
NhanLuongBGSV merged 5 commits intoeclipse-autowrx:mainfrom
SangNT12:main

Conversation

@SangNT12
Copy link
Contributor

@SangNT12 SangNT12 commented Feb 26, 2026

Overview

Improves the user experience when duplicate prototype names are encountered by providing helpful suggestions and better visual feedback during error correction.

Changes

Backend (fac9edc)

  • Show model name instead of ID in error messages
  • Generate and suggest 3 available alternative names when duplicate detected
  • Strip trailing number suffixes to create clean name suggestions (e.g., "test_2" → "test")
  • Extract duplicate error handling into throwDuplicateNameError helper function
  • Apply consistent behavior across createPrototype, bulkCreatePrototypes, and updatePrototypeById

Frontend

  • FormCreatePrototype (075ecfa): Display error message directly below name input with secondary color border highlight
  • PrototypeTabInfo (10d9b7b): Show detailed error with suggestions below input, highlight border on validation error, keep form in edit mode for easy correction
  • Align with design system colors for consistency

User Benefit

Users now receive actionable error messages with name suggestions when duplicates occur, making it easier to resolve naming conflicts without confusion.

#332

SangNT added 4 commits February 26, 2026 14:31
- Show model name instead of ID in error messages
- Generate and suggest 3 available alternative names when duplicate detected
- Strip trailing number suffix to create clean name suggestions (e.g., "test_2" → "test")
- Extract duplicate error handling into throwDuplicateNameError helper function
- Apply consistent behavior across createPrototype, bulkCreatePrototypes, and updatePrototypeById
- Display error message directly below name input
- Highlight input border with secondary color on validation error
- Align with design system colors for consistency
- Highlight input border on validation error
- Stay in edit mode on error for easy correction
@NhanLuongBGSV
Copy link
Contributor

image

@SangNT12 please help me check this

@SangNT12
Copy link
Contributor Author

SangNT12 commented Mar 4, 2026

image @SangNT12 please help me check this

A @NhanLuongBGSV I've just fixed this issue. Thanks.

@NhanLuongBGSV NhanLuongBGSV merged commit a2c213a into eclipse-autowrx:main Mar 6, 2026
1 check failed
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.

2 participants