@extends('layouts.portal')
@section('title', 'Create Profile')
@section('page_title', 'Step 1: Personal Details')
@section('page_subtitle', 'Complete your profile information')
@section('sidebar')
@include('client.partials.onboarding-sidebar', ['step' => 1, 'onboardingStep' => $onboardingStep])
@endsection
@section('content')
@include('components.form-styles')
@if(!$hasEditAccess)
Read-Only Mode
Your profile is in read-only mode. To edit, you need to request edit access.
Request Edit Access
@else
Edit Access Active
You can edit your profile until {{ $editRequest->edit_access_expires_at->format('d M Y, g:i A') }}
@endif
@include('components.unified-form', [
'title' => 'Personal Information',
'subtitle' => 'Please provide your personal details',
'action' => route('client.profile.store'),
'method' => 'POST',
'submitText' => 'Continue to Family Details',
'backUrl' => null,
'showSaveDraft' => $hasEditAccess,
'disabled' => !$hasEditAccess,
'icon' => '',
'sections' => [
[
'title' => 'Basic Information',
'icon' => '',
'grid' => 'grid-2',
'readonly' => !$hasEditAccess,
'fields' => [
[
'type' => 'text',
'name' => 'first_name',
'label' => 'First Name',
'required' => true,
'placeholder' => 'Enter your first name',
'value' => trim($onboardingStep->first_name ?? '', '"\''),
'readonly' => !$hasEditAccess,
'icon' => ''
],
[
'type' => 'text',
'name' => 'last_name',
'label' => 'Last Name',
'required' => true,
'placeholder' => 'Enter your last name',
'value' => trim($onboardingStep->last_name ?? '', '"\''),
'readonly' => !$hasEditAccess,
'icon' => ''
],
[
'type' => 'email',
'name' => 'email',
'label' => 'Email Address',
'required' => true,
'placeholder' => 'your.email@example.com',
'value' => trim($onboardingStep->user_email ?? '', '"\''),
'readonly' => !$hasEditAccess,
'icon' => ''
],
[
'type' => 'tel',
'name' => 'phone',
'label' => 'Phone Number',
'required' => true,
'placeholder' => '+60XX-XXXX-XXXX',
'value' => trim($onboardingStep->phone ?? '', '"\''),
'readonly' => !$hasEditAccess,
'icon' => ''
],
[
'type' => 'text',
'name' => 'ic_number',
'label' => 'IC/Passport Number',
'required' => true,
'placeholder' => 'e.g., A1234567 or H00000000',
'value' => trim($onboardingStep->ic_number ?? '', '"\''),
'readonly' => !$hasEditAccess,
'icon' => ''
],
[
'type' => 'text',
'name' => 'occupation',
'label' => 'Occupation',
'placeholder' => 'Your occupation',
'value' => trim($onboardingStep->occupation ?? '', '"\''),
'readonly' => !$hasEditAccess,
'icon' => ''
]
]
]
]
])
@endsection