{{-- Left-column category navigation on the seller storefront, mirroring the catalog's (partials.catalog.category-nav): «Все товары» + the seller's own categories, current one highlighted, collapsed after N. Тёплая панель, текущий раздел — белым (docs/design-inventory.md). --}} @php($collapseAfter = 10) @php($navItem = 'block rounded-[var(--radius-md)] px-3 py-2 text-[15px] leading-snug transition') @php($navOn = 'bg-white font-bold text-[var(--color-ink)]') @php($navOff = 'text-[var(--color-slate)] hover:bg-white hover:text-[var(--color-ink)]')
Разделы
Все товары
@foreach ($categories as $i => $cat) @php($isCurrent = $activeCategory === $cat->id) = $collapseAfter && ! $isCurrent) x-show="expanded" x-cloak @endif class="{{ $navItem }} {{ $isCurrent ? $navOn : $navOff }}"> {{ $cat->name }} @endforeach @if ($categories->count() > $collapseAfter) @endif