diff --git a/resources/views/components/accordion/item.blade.php b/resources/views/components/accordion/item.blade.php index d934de2..590ec35 100644 --- a/resources/views/components/accordion/item.blade.php +++ b/resources/views/components/accordion/item.blade.php @@ -11,6 +11,18 @@ id: $id('accordion'), @if($isIsolated) activeAccordion: 'accordion-{{ $activeAccordion }}', @endif }" + + :x-on:form-validation-error.window=" + $nextTick(() => { + let error = $el.querySelector('[data-validation-error]'); + + if (! error) { + return + } + + setActiveAccordion($id('accordion')); + }) + " class="fi-accordion-item group" >