@php use Filament\Support\Contracts\HasColor; use Filament\Support\Contracts\HasLabel; use Filament\Support\Contracts\HasIcon; $isHtmlAllowed = $field->isHtmlAllowed(); @endphp
@if (is_array($value)) @foreach ($value as $label) @if ($isHtmlAllowed) {!! $label !!} @else {{ $label }} @endif @endforeach @elseif($field->is('enum')) @php $label = $value instanceof HasLabel ? $value->getLabel() : $value; $color = $value instanceof HasColor ? $value->getColor() : $field->badgeColor; $icon = $value instanceof HasIcon ? $value->getIcon() : null; @endphp @if ($isHtmlAllowed) {!! $label !!} @else {{ $label }} @endif @else @if ($isHtmlAllowed) {!! $value !!} @else {{ $value }} @endif @endif