You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When creating a Grid field with any field as its "child" that has validation rules, the errors corresponding to said rules are set on the item index and not the item itself. Meaning that when I have 3 grid items and I get an validation error on item 2 (thus item 1 and 3 being valid), when I then remove item 2 the validation error doesn't go away but instead item 3 is now in the position of where item 2 was and now the validation error appears on item 3.
How to reproduce
Create a simple grid field with a field having a validation rule as its "child". YAML example:
Bug description
When creating a Grid field with any field as its "child" that has validation rules, the errors corresponding to said rules are set on the item index and not the item itself. Meaning that when I have 3 grid items and I get an validation error on item 2 (thus item 1 and 3 being valid), when I then remove item 2 the validation error doesn't go away but instead item 3 is now in the position of where item 2 was and now the validation error appears on item 3.
How to reproduce
Create a simple grid field with a field having a validation rule as its "child". YAML example:
Use it in an entry with some empty rows, try to save, see the validation errors and try to remove those rows with validation errors.
A screencap to hopefully provide more clarity:
Screen.Recording.2024-08-27.at.09.59.00.mov
Logs
No response
Environment
Installation
Fresh statamic/statamic site via CLI
Additional details
No response
The text was updated successfully, but these errors were encountered: