@props([ 'action' => 'submit', 'label' => "You have changes that haven't been saved yet.", // Optional comma-separated Livewire properties. When set, the bar only // appears when those fields differ from the last server snapshot — not on // incidental component state (e.g. $wire.set from x-init, display-only props). 'targets' => null, ]) {{-- Floating "unsaved changes" pill (bottom center). Reveals itself via Livewire's wire:dirty whenever the surrounding component has un-saved model changes. Instant-save controls (listboxes with onChange, $wire.set + submit, etc.) briefly mark the component dirty before the round-trip clears it. A delayed show + hide-while-loading swallows that flash so the bar only appears for real pending edits. Hide has no delay so Save still feels snappy. Mobile: stacked layout (full label, buttons on the next line) inset from the viewport edges so body overflow-x-clip cannot clip it. Desktop: compact single-row centered pill. --}}
{{ $label }}