{{-- sur le tag --}} {{-- :options="['defaultDate' => 'today']" --}} @props(['name', 'error' => null, 'options' => [], 'required' => false]) @php $label = $attributes['label'] ?? false; $placeholder = $attributes['placeholder'] ?? ''; $error = json_decode($error, true) ?? []; $options = array_merge( [ 'enableTime' => false, 'dateFormat' => 'Y-m-d', 'altInput' => true, 'altFormat' => 'd/m/y', // 'defaultDate' => 'today', 'locale.firstDayOfWeek' => 1, // 'disableMobile' => true, ], $options, ); @endphp
@if (!empty($error[0]))
@endif @if ($label) @endif
merge(['class' => 'input-date w-full appearance-none border-0 bg-transparent text-black py-1 px-0 focus:outline-none h-8 focus:border-transparent']) }} />
@if (!empty($error[0]))
{{ $error[0] }}
@endif