{{-- ? To set: * required: input_id as string for id tag array option: label as string html input_name as string if empty = input_id input_class as string for custom css class in input field input_attr as string for custom attr in input field {{ ! activ in textarea ! }} title as string for tooltip img_src as string accept_format as string default image optional qr required as boolean default false multiple as boolean default false max_file_size as float in MB -> default 15 MB dont_auto_show_scanner as boolean default flase ? QR Scanner URL: https://blog.minhazav.dev/research/html5-qrcode ? To implement in Blade: * @includeIf('layouts.components.file_upload', [ 'input_id' => 'example', ]) --}} @if ( !empty($input_id) ) @php $component_name = 'file_upload'; $uuid = $input_id .'_' .uniqid(); @endphp {{-- @section('section-css') @parent @once @endonce @stop --}}
@if ( !empty($label) ) @endif @if ( !empty($accept_format) && strtoupper($accept_format) === 'QR' )
@else {{-- @once @endonce --}}
{{-- --}}
@error ( $input_name ?? $input_id )
{{ $message }}
@enderror @endif
@section('section-js') @parent @once @if ( !empty($accept_format) && strtoupper($accept_format) === 'QR' && empty($dont_auto_show_scanner) ) @endif @endonce @stop @endif