HEX
Server: Microsoft-IIS/8.5
System: Windows NT YDAWBH120 6.3 build 9600 (Windows Server 2012 R2 Standard Edition) AMD64
User: tentjecom_web (0)
PHP: 7.4.14
Disabled: NONE
Upload Files
File: D:/HostingSpaces/SBogers10/kemi.komma.pro/resources/views/site/pages/projects/show.blade.php
@extends('site.master')

@section('title', $project->translation->name . ' | ' . $page->translation->meta_title)
@section('meta_description', $project->translation->meta_description)

@php
    \Carbon\Carbon::setLocale('nl');
    setlocale(LC_ALL, 'nl_NL');
@endphp

@section('content')
    <section class="content">

        {{--@include('site.partials.production-header', [ 'block' => $page->translation->header, 'subpage' => true ])--}}
        @if(isset($links->projects))
            <div class="grid-row full-row project-detail-header">

                <a class="return-to-overview" href="/{{$links->projects->route}}">
                    <div class="back-button">
                        @include('svg.arrow')
                        <span class="text">@lang('site/global.backToOverview')</span>
                    </div>
                </a>

                <div class="grid-col">
                    <div class="grid-row">
                        <div class="grid-col left">
                            <h4>@lang('site/global.menu')</h4>
                            <a href="/{{$links->projects->route}}">{{$links->projects->name}}</a>
                            <span class="small-arrow">&gt;</span>
                            {{$project->translation->name}}
                            <a href="#project" class="scroll-to-target">
                                <div class="back-button">
                                    @include('svg.arrow')
                                </div>
                            </a>
                        </div>

                        <div class="grid-col right">
                            <div class="white-block">
                                <h4>{{\Carbon\Carbon::parse($project->date)->formatLocalized('%d %B %Y')}}</h4>

                                <div class="header-content">
                                    {!! $project->translation->name  !!}
                                </div>
                            </div>
                        </div>
                    </div>
                </div>
            </div>

        @endif

        @if(isset($primaryBlock) && $primaryBlock->typeSlug === 'content-block')
            <div class="grid-row full-row project-block" id="project">
                <div class="grid-col {{$primaryBlock->location}}">
                    <div class="grid-row">
                        @if($primaryBlock->location === "right")
                            <div class="grid-col content kms-content">
                                {!! $primaryBlock->description !!}
                            </div>
                        @endif
                        <div class="grid-col image {{$primaryBlock->location}}">

                            @if(isset($primaryBlock->images) && sizeof($primaryBlock->images) > 1)
                                <div id="image-slider-primary" class="image-slider">
                                    <div class="placeholder">
                                        @foreach($primaryBlock->images as $imageSlide)
                                            <figure data-order="{{$loop->index}}" class="image-placeholder">
                                                @foreach(['large', 'medium', 'small'] as $imageSize)
                                                    <span class="{{$imageSize}}"
                                                          style="background-image: url('{{ $imageSlide[$imageSize] }}');"></span>
                                                @endforeach
                                            </figure>
                                        @endforeach

                                        <div class="controllers">
                                            <div class="nav-item previous"
                                                 data-order="{{(sizeof($primaryBlock->images) - 1)}}">
                                                <span>@include('svg.arrow')</span>
                                            </div>

                                            <div class="nav-item next" data-order="1">
                                                <span>@include('svg.arrow')</span>
                                            </div>
                                        </div>
                                    </div>
                                </div>
                            @else
                                <figure class="medium"
                                        @isset($primaryBlock->images[0])
                                        style="background-image: url('{{$primaryBlock->images[0]['medium']}}')"
                                        @endisset
                                >
                                    @if(isset($primaryBlock->images[0]))
                                        <img alt="impression" src="{{$primaryBlock->images[0]['medium']}}"/>
                                    @endif
                                </figure>
                            @endif
                        </div>
                        @if($primaryBlock->location === "left")
                            <div class="grid-col content kms-content">
                                {!! $primaryBlock->description !!}
                            </div>
                        @endif
                    </div>
                </div>
            </div>
        @else
            <div class="grid-row full-row project-block" id="project">
                <div class="grid-col right">
                    <div class="grid-row">
                        <div class="grid-col image"></div>
                        <div class="grid-col content">
                            <h2>Oeps</h2>
                            <p>Eerste dynamic blok zou een 'Afbeelding en tekst' blok moeten zijn.</p>
                        </div>
                    </div>
                </div>
            </div>
        @endif

        @if(sizeof($project->translation->description) > 1)
            <section class="dynamic-content">
                <div class="grid-row">

                    @foreach($project->translation->description as $block)

                        {{-- Skip if status is false or it has a codename | if the first item is typeSlug it has already been used for the above block --}}
                        @continue( !($block->status && isset($block->code_name) && $block->code_name == '') || ($loop->first && $block->typeSlug === 'content-block') )

                        @if(isset($block->view) && $block->view != '')
                            @include($block->view, ['order' => $loop->index])
                        @else
                            @include('site.partials.dynamic.'.$block->typeSlug, ['order' => $loop->index])
                        @endif

                    @endforeach

                </div>
            </section>
        @endif

        @include('site.partials.CTA-bottom')
    </section>
@endsection