- Status changed to Needs review
over 1 year ago 5:58am 17 January 2023 - ๐ฎ๐ณIndia Charchil Khandelwal
Charchil Khandelwal โ made their first commit to this issueโs fork.
- last update
8 months ago 180 pass - ๐ง๐ชBelgium herved
Argh, I just stumbled on this, more specifically the issue described in ๐ Constraints on paragraph field highlight all fields in paragraph Needs review .
I think the approach here makes more sense sincearrayPropertyPath
is deprecated.But patch #2 is not working for me: it doesn't remove the delta and doesn't pass the full path.
I have the following violation path:$delta.subform.my_date_field.widget
The delta should be removed just like\Drupal\Core\Field\WidgetBase::flagErrors
does:// Separate violations by delta. $property_path = explode('.', $violation->getPropertyPath()); $delta = array_shift($property_path); ... $violation->arrayPropertyPath = $property_path;
Because it later passes the
$delta_element
toWidgetBase::errorElement
This wayNestedArray::getValue()
would get['subform', 'my_date_field', 'widget']
which is correct and returns the sub-element properly.