@props([ 'name' => '', 'value' => null, 'label' => '', 'class' => '', 'format' => 'Y-m-d', 'dateFormat' => 'dateFormat', 'star' => false, 'minDate' => null, 'maxDate' => null, 'tooltip' => null, ]) @php $splitAttributes = implode(' ', explode(' ', $attributes)); $invalidClass = $errors->has(dotted_string($name)) ? 'is-invalid' : ''; $class = "{$invalidClass} form-control {$class} {$dateFormat}"; $defaultPlaceHolder = __('Enter') . ' ' . $label; $placeholder = $placeholder ?? $defaultPlaceHolder; $value = $value ?? (isset($model) ? old($name, $model->{$name}) : old($name)); $dotted_name = dotted_string($name); @endphp