<div class="d-flex justify-content-end flex-shrink-0">
@foreach($buttons as $button)
    <a @if($button['type'] == 'link')
           href="{{$button['route']}}"
       @else
           href="javascript:void(0)" data-route="{{$button['route']}}" @isset($button['id']) data-id="{{$button['id']}}" @endisset
       @endif
        @if(isset($button['attributes']) && is_array($button['attributes']))
            @foreach($button['attributes'] as $attributeKey => $attribute)
                {{$attributeKey}}="{{$attribute}}"
            @endforeach
        @endif
        class="btn btn-icon btn-bg-light btn-active-color-primary btn-sm me-1 @isset($button['class']) {{$button['class']}} @endif @if($button['type'] == 'ajax') ajax-button @endif" title="{{$button['label'] ?? ''}}">
        @if(isset($button['icon']))
            <i class="ki-outline ki-{{$button['icon']}} fs-2"></i>
        @else
            {{$button['label']}}
        @endif
    </a>
@endforeach
</div>
