@props([ 'submitLabel' => null, 'cancelUrl' => null, 'cancelLabel' => null, 'loading' => false, 'loadingLabel' => null, 'align' => 'start', 'sticky' => false, ]) @php $submitLabel = $submitLabel ?: __('kview-ui-core::ui.common.save'); $cancelLabel = $cancelLabel ?: __('kview-ui-core::ui.common.cancel'); $loadingLabel = $loadingLabel ?: __('kview-ui-core::ui.common.saving'); $align = in_array($align, ['start', 'end', 'between'], true) ? $align : 'start'; $hasSlot = trim((string) $slot) !== ''; @endphp
class([ 'ui-form-actions', 'ui-form-actions--'.$align, 'ui-form-actions--sticky' => $sticky, ]) }} data-ui-form-actions> @if ($hasSlot) {{ $slot }} @else @if ($cancelUrl) {{ $cancelLabel }} @endif @endif