@props([
'customAttributes' => [],
'entity' => null,
'allowEdit' => false,
'url' => null,
])
@foreach ($customAttributes as $attribute)
@if (view()->exists($typeView = 'admin::components.attributes.view.' . $attribute->type))
{{ $attribute->name }}
@include ($typeView, [
'attribute' => $attribute,
'value' => isset($entity) ? $entity[$attribute->code] : null,
'allowEdit' => $allowEdit,
'url' => $url,
])
@endif
@endforeach