{{-- Modal Component - AdminLTE Theme Based on AdminLTE v4 Modal styling patterns Usage: Content Open with: $dispatch('open-modal', { name: 'my-modal' }) Close with: $dispatch('close-modal', { name: 'my-modal' }) --}} @props([ 'name', 'title' => null, 'subtitle' => null, 'icon' => null, 'iconColor' => 'lte-text-primary', 'maxWidth' => 'md', 'closeable' => true, 'footer' => null, ]) @php $maxWidthClasses = [ 'sm' => 'max-w-sm', 'md' => 'max-w-md', 'lg' => 'max-w-lg', 'xl' => 'max-w-xl', '2xl' => 'max-w-2xl', '3xl' => 'max-w-3xl', '4xl' => 'max-w-4xl', '5xl' => 'max-w-5xl', 'full' => 'max-w-full mx-4', ]; $maxWidthClass = $maxWidthClasses[$maxWidth] ?? $maxWidthClasses['md']; @endphp
{{-- Backdrop --}}
{{-- Modal Panel --}}
{{-- Header --}} @if($title || $closeable)
@if($icon) @endif
@if($title)
{{ $title }}
@endif @if($subtitle)

{{ $subtitle }}

@endif
@if($closeable) @endif
@endif {{-- Content --}}
{{ $slot }}
{{-- Footer --}} @if($footer) @endif