@extends('web.layouts.container') @section('header')

{{$pageDetails->description}}

{{__('main.scroll_down')}}
@endsection @section('content')

{{$chairman?$chairman->name:null}}

{{$chairman?$chairman->job_title:null}}

{{$chairman?$chairman->details:null}}

{{-- @php--}} {{-- $details = $chairman ? str_split($chairman->details_plus, round(mb_strlen($chairman->details_plus)/4)) : [];--}} {{-- $announce = $chairman ? str_split($chairman->company_announce, round(mb_strlen($chairman->company_announce)/2)) : [];--}} {{-- @endphp--}} @php //$details = $chairman ? str_split($chairman->details_plus, (int) round(count(preg_split('/\s+/', trim(preg_replace('/\s\s+/', ' ', $chairman->details_plus))))/2)) : []; //$announce = $chairman ? str_split($chairman->company_announce, round(count(preg_split('/\s+/', $chairman->company_announce))/2)) : []; $announce = explode('@@', $chairman->company_announce, 2); //$details = trim(preg_replace('/\s\s+/', ' ', $chairman->details_plus)); $details = explode('@@', $chairman->details_plus, 4); //$details = array_chunk($details, (int) ceil(count($details)/4)); //$section1 = implode(' ',$details[0]); //$section2 = implode(' ',$details[1]); //$section3 = implode(' ',$details[2]); //$section4 = implode(' ',$details[3]); @endphp

{!! $details[0] !!}

{!! $details[1] !!}

{!! $details[2] !!}

{!! $details[3] !!}

{{count($announce) ? $announce[0] : ''}}

{{count($announce) ? $announce[1] : ''}}

{{__('main.our_leadership')}}

@foreach ($leaderships as $leadership) @if ($loop->iteration == 5) @break @endif
@php $job_title = preg_match('/@@/', $leadership->job_title) ? explode('@@', $leadership->job_title) : $leadership->job_title; @endphp

{{$leadership->name}}

@if (is_array($job_title)) {{$job_title[0]}}
{{$job_title[1]}} @else {{$job_title}} @endif

{{$leadership->details}}

@endforeach
@foreach ($leaderships as $leadership) @if ($loop->iteration < 5) @continue @endif
@php $job_title = preg_match('/@@/', $leadership->job_title) ? explode('@@', $leadership->job_title) : $leadership->job_title; @endphp

{{$leadership->name}}

@if (is_array($job_title)) {{$job_title[0]}}
{{$job_title[1]}} @else {{$job_title}} @endif

{{$leadership->details}}

@endforeach
@endsection @section('inner_js') @endsection