@php // Switched off in Admin -> Pages: the band does not draw, on any layout that includes it. if (!section_on('popular-restaurants')) { return; } /** * Popular Restaurants — curated, editorial restaurant rails (top-rated / fastest / newest). * This is house CURATION, not advertising: every card is a real restaurant pulled from a * ranking query. The section carries exactly two genuine ad slots, both dynamic and both * rendered through cards/ad with their own "Sponsored" label: * - "home_tall" — the tall column beside the first rail * - "home_card" — the fourth card in the last rail * With no campaign booked either slot falls back to the theme-options image, never a * hardcoded promo. * @var array $collections list of ['title','subtitle','url','items'] */ $collections = collect($collections ?? [])->all(); // accepts an array or a collection // Only rails that actually have restaurants, so the slot indexes below stay stable // even when a rail is skipped for having nothing unique left to show. $rails = array_values(array_filter($collections, static fn (array $c): bool => !empty($c['items']))); if (!$rails) { return; } $lastIdx = count($rails) - 1; $tallAd = active_ad('home_tall'); $cardAd = active_ad('home_card'); /** Up to 3 curated restaurant cards for a rail (thirds). */ $cards = function (array $items) use ($__env): string { ob_start(); @endphp
{{ $col['subtitle'] }}
@endif