| Current Path : /var/www/html/dynaweb-starter/storage/framework/views/ |
| Current File : /var/www/html/dynaweb-starter/storage/framework/views/ea546950d12fb6e6354e6a601b4060ac.php |
<?php if (isset($component)) { $__componentOriginal511d4862ff04963c3c16115c05a86a9d = $component; } ?>
<?php $component = Illuminate\View\DynamicComponent::resolve(['component' => $getFieldWrapperView()] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?>
<?php $component->withName('dynamic-component'); ?>
<?php if ($component->shouldRender()): ?>
<?php $__env->startComponent($component->resolveView(), $component->data()); ?>
<?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(Illuminate\View\DynamicComponent::class))->getConstructor()): ?>
<?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?>
<?php endif; ?>
<?php $component->withAttributes(['field' => $field]); ?>
<?php
$gridDirection = $getGridDirection() ?? 'column';
$isBulkToggleable = $isBulkToggleable();
$isDisabled = $isDisabled();
$isSearchable = $isSearchable();
$statePath = $getStatePath();
?>
<div
x-data="{
areAllCheckboxesChecked: false,
checkboxListOptions: Array.from(
$root.querySelectorAll('.fi-fo-checkbox-list-option-label'),
),
search: '',
visibleCheckboxListOptions: [],
init: function () {
this.updateVisibleCheckboxListOptions()
$nextTick(() => {
this.checkIfAllCheckboxesAreChecked()
})
Livewire.hook(
'commit',
({ component, commit, succeed, fail, respond }) => {
succeed(({ snapshot, effect }) => {
$nextTick(() => {
if (component.id !== <?php echo \Illuminate\Support\Js::from($this->getId())->toHtml() ?>) {
return
}
this.checkboxListOptions = Array.from(
$root.querySelectorAll(
'.fi-fo-checkbox-list-option-label',
),
)
this.updateVisibleCheckboxListOptions()
this.checkIfAllCheckboxesAreChecked()
})
})
},
)
$watch('search', () => {
this.updateVisibleCheckboxListOptions()
this.checkIfAllCheckboxesAreChecked()
})
},
checkIfAllCheckboxesAreChecked: function () {
this.areAllCheckboxesChecked =
this.visibleCheckboxListOptions.length ===
this.visibleCheckboxListOptions.filter((checkboxLabel) =>
checkboxLabel.querySelector('input[type=checkbox]:checked'),
).length
},
toggleAllCheckboxes: function () {
state = ! this.areAllCheckboxesChecked
this.visibleCheckboxListOptions.forEach((checkboxLabel) => {
checkbox = checkboxLabel.querySelector('input[type=checkbox]')
checkbox.checked = state
checkbox.dispatchEvent(new Event('change'))
})
this.areAllCheckboxesChecked = state
},
updateVisibleCheckboxListOptions: function () {
this.visibleCheckboxListOptions = this.checkboxListOptions.filter(
(checkboxListItem) => {
if (
checkboxListItem
.querySelector('.fi-fo-checkbox-list-option-label')
?.innerText.toLowerCase()
.includes(this.search.toLowerCase())
) {
return true
}
return checkboxListItem
.querySelector('.fi-fo-checkbox-list-option-description')
?.innerText.toLowerCase()
.includes(this.search.toLowerCase())
},
)
},
}"
>
<!--[if BLOCK]><![endif]--><?php if(! $isDisabled): ?>
<!--[if BLOCK]><![endif]--><?php if($isSearchable): ?>
<?php if (isset($component)) { $__componentOriginal71c6471fa76ce19017edc287b6f4508c = $component; } ?>
<?php $component = Illuminate\View\AnonymousComponent::resolve(['view' => 'filament::components.input.wrapper','data' => ['inlinePrefix' => true,'prefixIcon' => 'heroicon-m-magnifying-glass','prefixIconAlias' => 'forms:components.checkbox-list.search-field','class' => 'mb-4']] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?>
<?php $component->withName('filament::input.wrapper'); ?>
<?php if ($component->shouldRender()): ?>
<?php $__env->startComponent($component->resolveView(), $component->data()); ?>
<?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(Illuminate\View\AnonymousComponent::class))->getConstructor()): ?>
<?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?>
<?php endif; ?>
<?php $component->withAttributes(['inline-prefix' => true,'prefix-icon' => 'heroicon-m-magnifying-glass','prefix-icon-alias' => 'forms:components.checkbox-list.search-field','class' => 'mb-4']); ?>
<?php if (isset($component)) { $__componentOriginal71c6471fa76ce19017edc287b6f4508c = $component; } ?>
<?php $component = Illuminate\View\AnonymousComponent::resolve(['view' => 'filament::components.input.index','data' => ['inlinePrefix' => true,'placeholder' => $getSearchPrompt(),'type' => 'search','attributes' =>
\Filament\Support\prepare_inherited_attributes(
new \Illuminate\View\ComponentAttributeBag([
'x-model.debounce.' . $getSearchDebounce() => 'search',
])
)
]] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?>
<?php $component->withName('filament::input'); ?>
<?php if ($component->shouldRender()): ?>
<?php $__env->startComponent($component->resolveView(), $component->data()); ?>
<?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(Illuminate\View\AnonymousComponent::class))->getConstructor()): ?>
<?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?>
<?php endif; ?>
<?php $component->withAttributes(['inline-prefix' => true,'placeholder' => \Illuminate\View\Compilers\BladeCompiler::sanitizeComponentAttribute($getSearchPrompt()),'type' => 'search','attributes' => \Illuminate\View\Compilers\BladeCompiler::sanitizeComponentAttribute(
\Filament\Support\prepare_inherited_attributes(
new \Illuminate\View\ComponentAttributeBag([
'x-model.debounce.' . $getSearchDebounce() => 'search',
])
)
)]); ?>
<?php echo $__env->renderComponent(); ?>
<?php endif; ?>
<?php if (isset($__componentOriginal71c6471fa76ce19017edc287b6f4508c)): ?>
<?php $component = $__componentOriginal71c6471fa76ce19017edc287b6f4508c; ?>
<?php unset($__componentOriginal71c6471fa76ce19017edc287b6f4508c); ?>
<?php endif; ?>
<?php echo $__env->renderComponent(); ?>
<?php endif; ?>
<?php if (isset($__componentOriginal71c6471fa76ce19017edc287b6f4508c)): ?>
<?php $component = $__componentOriginal71c6471fa76ce19017edc287b6f4508c; ?>
<?php unset($__componentOriginal71c6471fa76ce19017edc287b6f4508c); ?>
<?php endif; ?>
<?php endif; ?> <!--[if ENDBLOCK]><![endif]-->
<!--[if BLOCK]><![endif]--><?php if($isBulkToggleable && count($getOptions())): ?>
<div
x-cloak
class="mb-2"
wire:key="<?php echo e($this->getId()); ?>.<?php echo e($getStatePath()); ?>.<?php echo e($field::class); ?>.actions"
>
<span
x-show="! areAllCheckboxesChecked"
x-on:click="toggleAllCheckboxes()"
wire:key="<?php echo e($this->getId()); ?>.<?php echo e($statePath); ?>.<?php echo e($field::class); ?>.actions.select_all"
>
<?php echo e($getAction('selectAll')); ?>
</span>
<span
x-show="areAllCheckboxesChecked"
x-on:click="toggleAllCheckboxes()"
wire:key="<?php echo e($this->getId()); ?>.<?php echo e($statePath); ?>.<?php echo e($field::class); ?>.actions.deselect_all"
>
<?php echo e($getAction('deselectAll')); ?>
</span>
</div>
<?php endif; ?> <!--[if ENDBLOCK]><![endif]-->
<?php endif; ?> <!--[if ENDBLOCK]><![endif]-->
<?php if (isset($component)) { $__componentOriginal71c6471fa76ce19017edc287b6f4508c = $component; } ?>
<?php $component = Illuminate\View\AnonymousComponent::resolve(['view' => 'filament::components.grid.index','data' => ['default' => $getColumns('default'),'sm' => $getColumns('sm'),'md' => $getColumns('md'),'lg' => $getColumns('lg'),'xl' => $getColumns('xl'),'twoXl' => $getColumns('2xl'),'direction' => $gridDirection,'xShow' => $isSearchable ? 'visibleCheckboxListOptions.length' : null,'attributes' =>
\Filament\Support\prepare_inherited_attributes($attributes)
->merge($getExtraAttributes(), escape: false)
->class([
'fi-fo-checkbox-list gap-4',
'-mt-4' => $gridDirection === 'column',
])
]] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?>
<?php $component->withName('filament::grid'); ?>
<?php if ($component->shouldRender()): ?>
<?php $__env->startComponent($component->resolveView(), $component->data()); ?>
<?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(Illuminate\View\AnonymousComponent::class))->getConstructor()): ?>
<?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?>
<?php endif; ?>
<?php $component->withAttributes(['default' => \Illuminate\View\Compilers\BladeCompiler::sanitizeComponentAttribute($getColumns('default')),'sm' => \Illuminate\View\Compilers\BladeCompiler::sanitizeComponentAttribute($getColumns('sm')),'md' => \Illuminate\View\Compilers\BladeCompiler::sanitizeComponentAttribute($getColumns('md')),'lg' => \Illuminate\View\Compilers\BladeCompiler::sanitizeComponentAttribute($getColumns('lg')),'xl' => \Illuminate\View\Compilers\BladeCompiler::sanitizeComponentAttribute($getColumns('xl')),'two-xl' => \Illuminate\View\Compilers\BladeCompiler::sanitizeComponentAttribute($getColumns('2xl')),'direction' => \Illuminate\View\Compilers\BladeCompiler::sanitizeComponentAttribute($gridDirection),'x-show' => \Illuminate\View\Compilers\BladeCompiler::sanitizeComponentAttribute($isSearchable ? 'visibleCheckboxListOptions.length' : null),'attributes' => \Illuminate\View\Compilers\BladeCompiler::sanitizeComponentAttribute(
\Filament\Support\prepare_inherited_attributes($attributes)
->merge($getExtraAttributes(), escape: false)
->class([
'fi-fo-checkbox-list gap-4',
'-mt-4' => $gridDirection === 'column',
])
)]); ?>
<!--[if BLOCK]><![endif]--><?php $__empty_1 = true; $__currentLoopData = $getOptions(); $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $value => $label): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); $__empty_1 = false; ?>
<div
wire:key="<?php echo e($this->getId()); ?>.<?php echo e($statePath); ?>.<?php echo e($field::class); ?>.options.<?php echo e($value); ?>"
<?php if($isSearchable): ?>
x-show="
$el
.querySelector('.fi-fo-checkbox-list-option-label')
?.innerText.toLowerCase()
.includes(search.toLowerCase()) ||
$el
.querySelector('.fi-fo-checkbox-list-option-description')
?.innerText.toLowerCase()
.includes(search.toLowerCase())
"
<?php endif; ?>
class="<?php echo \Illuminate\Support\Arr::toCssClasses([
'break-inside-avoid pt-4' => $gridDirection === 'column',
]); ?>"
>
<label
class="fi-fo-checkbox-list-option-label flex gap-x-3"
>
<?php if (isset($component)) { $__componentOriginal71c6471fa76ce19017edc287b6f4508c = $component; } ?>
<?php $component = Illuminate\View\AnonymousComponent::resolve(['view' => 'filament::components.input.checkbox','data' => ['error' => $errors->has($statePath),'attributes' =>
\Filament\Support\prepare_inherited_attributes($getExtraInputAttributeBag())
->merge([
'disabled' => $isDisabled || $isOptionDisabled($value, $label),
'value' => $value,
'wire:loading.attr' => 'disabled',
$applyStateBindingModifiers('wire:model') => $statePath,
'x-on:change' => $isBulkToggleable ? 'checkIfAllCheckboxesAreChecked()' : null,
], escape: false)
->class(['mt-1'])
]] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?>
<?php $component->withName('filament::input.checkbox'); ?>
<?php if ($component->shouldRender()): ?>
<?php $__env->startComponent($component->resolveView(), $component->data()); ?>
<?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(Illuminate\View\AnonymousComponent::class))->getConstructor()): ?>
<?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?>
<?php endif; ?>
<?php $component->withAttributes(['error' => \Illuminate\View\Compilers\BladeCompiler::sanitizeComponentAttribute($errors->has($statePath)),'attributes' => \Illuminate\View\Compilers\BladeCompiler::sanitizeComponentAttribute(
\Filament\Support\prepare_inherited_attributes($getExtraInputAttributeBag())
->merge([
'disabled' => $isDisabled || $isOptionDisabled($value, $label),
'value' => $value,
'wire:loading.attr' => 'disabled',
$applyStateBindingModifiers('wire:model') => $statePath,
'x-on:change' => $isBulkToggleable ? 'checkIfAllCheckboxesAreChecked()' : null,
], escape: false)
->class(['mt-1'])
)]); ?>
<?php echo $__env->renderComponent(); ?>
<?php endif; ?>
<?php if (isset($__componentOriginal71c6471fa76ce19017edc287b6f4508c)): ?>
<?php $component = $__componentOriginal71c6471fa76ce19017edc287b6f4508c; ?>
<?php unset($__componentOriginal71c6471fa76ce19017edc287b6f4508c); ?>
<?php endif; ?>
<div class="grid text-sm leading-6">
<span
class="fi-fo-checkbox-list-option-label font-medium text-gray-950 dark:text-white"
>
<?php echo e($label); ?>
</span>
<!--[if BLOCK]><![endif]--><?php if($hasDescription($value)): ?>
<p
class="fi-fo-checkbox-list-option-description text-gray-500 dark:text-gray-400"
>
<?php echo e($getDescription($value)); ?>
</p>
<?php endif; ?> <!--[if ENDBLOCK]><![endif]-->
</div>
</label>
</div>
<?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); if ($__empty_1): ?>
<div
wire:key="<?php echo e($this->getId()); ?>.<?php echo e($statePath); ?>.<?php echo e($field::class); ?>.empty"
></div>
<?php endif; ?> <!--[if ENDBLOCK]><![endif]-->
<?php echo $__env->renderComponent(); ?>
<?php endif; ?>
<?php if (isset($__componentOriginal71c6471fa76ce19017edc287b6f4508c)): ?>
<?php $component = $__componentOriginal71c6471fa76ce19017edc287b6f4508c; ?>
<?php unset($__componentOriginal71c6471fa76ce19017edc287b6f4508c); ?>
<?php endif; ?>
<!--[if BLOCK]><![endif]--><?php if($isSearchable): ?>
<div
x-cloak
x-show="search && ! visibleCheckboxListOptions.length"
class="fi-fo-checkbox-list-no-search-results-message text-sm text-gray-500 dark:text-gray-400"
>
<?php echo e($getNoSearchResultsMessage()); ?>
</div>
<?php endif; ?> <!--[if ENDBLOCK]><![endif]-->
</div>
<?php echo $__env->renderComponent(); ?>
<?php endif; ?>
<?php if (isset($__componentOriginal511d4862ff04963c3c16115c05a86a9d)): ?>
<?php $component = $__componentOriginal511d4862ff04963c3c16115c05a86a9d; ?>
<?php unset($__componentOriginal511d4862ff04963c3c16115c05a86a9d); ?>
<?php endif; ?>
<?php /**PATH /var/www/html/dynaweb-starter/vendor/filament/forms/src/../resources/views/components/checkbox-list.blade.php ENDPATH**/ ?>