<div>
    @if(!empty($data) && !empty($formInfo->id))
        <div class="card col-8 m-auto">
            <div class="card-header">
                {{$formInfo->name}}
            </div>
            <div class="card-body">
                @foreach($forms as $form)
                    <?php $val='' ?>
                    @if($form->type=='header')
                    <h1>{{ $form->label }}</h1>
                    @elseif($form->type=='paragraph')
                    <p>{{ $form->label }}</p>
                    @elseif(!empty($form->name) && !empty($form->label))
                        <?php $val=$form->name ?>
                        <div class="row">
                            <div class="col-6 text-end"><b>{{ $form->label }}: </b></div>
                            <div class="col-6 text-start"><p> @json($data->form_content[$val] ?? '')</p></div>
                        </div>
                    @elseif(!empty($form->label))
                        <p>{{ $form->label }}</p>
                    @endif()
                @endforeach
            </div>
        </div>
    @else
        <div>No Data Found</div>
    @endif
</div>
