@php $statePath = $getStatePath(); $groups = $getFieldGroups(); $labels = $getFieldLabels(); @endphp
{{-- wire:ignore is load-bearing. The pills live only in this DOM — the server renders this element empty and fills the value in through $wire — so without it every round trip (the preview is one) morphs the editor back to blank and the client watches their formula vanish as they type. --}}
{{-- Autocomplete, anchored to the editor. --}}
{{-- Operators and functions sit directly under the editor: they are reached on almost every formula, whereas any one field is reached once. The field palette below scrolls so it cannot push the rest of the form off the screen. --}} @if ($getOperators() || $getFunctionNames())
@foreach ($getOperators() as $operator) @endforeach @if ($getOperators() && $getFunctionNames()) @endif @foreach ($getFunctionNames() as $function) @endforeach
@endif {{-- Clicking a field is the primary way in; typing `{` is the shortcut. --}}
@foreach ($groups as $group => $fields)
{{ $group }}
@foreach ($fields as $paletteField) @endforeach
@endforeach