@props([ 'name', 'label' => null, 'type' => 'text', 'value' => null, 'hint' => null, 'required' => false, 'placeholder' => null, 'prefix' => null, ]) @php $id = $attributes->get('id') ?? $name; $hasError = $errors->has($name); $inputClass = 'hms-input'.($hasError ? ' border-red-400 focus:border-red-500 focus:ring-red-500' : ''); @endphp
@if ($label) @endif @if ($prefix)
{{ $prefix }} except(['id'])->merge(['class' => $inputClass.' rounded-l-none']) }}>
@else except(['id'])->merge(['class' => $inputClass]) }}> @endif @if ($hint && ! $hasError)

{{ $hint }}

@endif @error($name)

{{ $message }}

@enderror