{{-- Has a support for text, number, selectize (use selectOptions slot) --}} @props([ 'label' => null, 'helpText' => null, 'prepend' => null, 'append' => null, 'appendText' => null, 'prependText' => null, ]) @php $id = $attributes->get('id'); $dataType = $attributes->get('type'); $formGroupClass = $attributes->get('data-form-group-class') ?? ''; $inputGroupClass = $attributes->get('data-input-group-class') ?? ''; if (!$id) { $id = sha1(json_encode($attributes->getAttributes())); } @endphp
@if ($append or $appendText or $prepend or $prependText)
@if ($prepend)
{!! $prepend !!}
@endif @if ($prependText)
{!! $prependText !!}
@endif merge(['class' => 'lw-form-field form-control', 'type' => 'text', 'id' => $id]) !!} /> @if ($append)
{!! $append !!}
@endif @if ($appendText)
{!! $appendText !!}
@endif
@elseif(($dataType === 'selectize') or ($dataType === 'select')) @if ($dataType === 'select') @elseif($dataType === 'selectize') @endif @else merge(['class' => 'lw-form-field form-control', 'type' => 'text', 'id' => $id]) !!} /> @endif @if ($helpText) {{ $helpText }} @endif