@extends('layouts.portal')
@section('title', __($section['label']))
@section('content')
@include('partials.portal-header')
{{ __($definition['label']) }}
{{ __($section['label']) }}
{{ __($section['description'] ?? '') }}
← {{ __('Overview') }}
@php
$cards = collect($section['items'])
->reject(fn (array $item): bool => isset($item['can']) && ! auth()->user()?->can($item['can']))
->map(fn (array $item): array => [
'label' => $item['label'],
'description' => $item['description'] ?? '',
'url' => $item['route'] === null ? null : route($item['route']),
])
->all();
@endphp
@include('accounting._cards', ['cards' => $cards, 'label' => __($section['label'])])
@endsection