@php // Switched off in Admin -> Pages: the band does not draw, on any layout that includes it. /* Same band, more than one page. Each page owns its switch and its heading; the values fall back to the homepage's, so the homepage include is untouched by this. */ $sectionId = $sectionId ?? 'food-stories'; if (!section_on($sectionId)) { return; } /** * Food stories & tips — latest blog posts, rendered in the modern blog-card style * (qm-blogm-card) so the section matches the modern blog surfaces site-wide. * @var array $posts blog-post rows * @var string $cols Bootstrap column classes per post card (default 3-up on lg) */ $posts = collect($posts ?? [])->all(); // accepts an array or a collection if (empty($posts)) { return; } $cols = $cols ?? 'col-lg-4 col-md-6'; $limit = (int) ($limit ?? 0); // 0 = show all if ($limit > 0) { $posts = array_slice($posts, 0, $limit); } $storiesEyebrow = trim($storiesEyebrow ?? t_raw('home.stories.eyebrow')); $storiesTitle = trim($storiesTitle ?? t_raw('home.stories.title')); $storiesSub = trim($storiesSub ?? t_raw('home.stories.sub')); $storiesBtn = trim($storiesBtn ?? t_raw('home.stories.read_blog')); $storiesBtnUrlKey = $storiesBtnUrlKey ?? 'home.stories.read_blog_url'; @endphp
@if ($storiesEyebrow !== ''){{ $storiesEyebrow }}@endif @if ($storiesTitle !== '')

{{ $storiesTitle }}

@endif @if ($storiesSub !== '')

{{ $storiesSub }}

@endif
@if ($storiesBtn !== ''){{ $storiesBtn }}@endif
@foreach ($posts as $p)
@endforeach