refactor(register): enhance registration form with required field indicators and improved input placeholders
This commit is contained in:
parent
5b2f76162d
commit
402026ce09
@ -30,7 +30,6 @@ class="size-7 flex justify-center items-center shrink-0 font-medium text-gray-80
|
|||||||
|
|
||||||
<div
|
<div
|
||||||
class="ml-3 md:ml-0 md:mt-2 text-left md:text-center transition-all duration-300 ease-in-out">
|
class="ml-3 md:ml-0 md:mt-2 text-left md:text-center transition-all duration-300 ease-in-out">
|
||||||
<flux:text class="text-gray-500">Step</flux:text>
|
|
||||||
<flux:text
|
<flux:text
|
||||||
class="transition-all duration-500 ease-in-out {{ $currentStep === $step['id'] ? 'text-emerald-600 font-semibold' : '' }}">
|
class="transition-all duration-500 ease-in-out {{ $currentStep === $step['id'] ? 'text-emerald-600 font-semibold' : '' }}">
|
||||||
{{ $step['name'] }}
|
{{ $step['name'] }}
|
||||||
@ -43,44 +42,71 @@ class="transition-all duration-500 ease-in-out {{ $currentStep === $step['id'] ?
|
|||||||
@if ($currentStep === 1)
|
@if ($currentStep === 1)
|
||||||
<div class="flex flex-col gap-6">
|
<div class="flex flex-col gap-6">
|
||||||
<flux:field>
|
<flux:field>
|
||||||
<flux:label>Email</flux:label>
|
<flux:label>Email <span class="text-red-500 ms-1">*</span></flux:label>
|
||||||
|
|
||||||
<flux:description>Pastikan email aktif karena akan digunakan untuk verifikasi.
|
<flux:description>Pastikan email aktif karena akan digunakan untuk verifikasi.
|
||||||
</flux:description>
|
</flux:description>
|
||||||
|
|
||||||
<flux:input placeholder="Masukkan email" wire:model.live.debounce.500ms="form.email" autofocus
|
<flux:input placeholder="info.pangestuyoga@gmail.com" wire:model.live="form.email" autofocus
|
||||||
autocomplete="off" />
|
autocomplete="off" />
|
||||||
|
|
||||||
<flux:error name="form.email" />
|
<flux:error name="form.email" />
|
||||||
</flux:field>
|
</flux:field>
|
||||||
|
|
||||||
<flux:input label="Nama Pengguna" placeholder="Masukkan nama pengguna"
|
<flux:field>
|
||||||
wire:model.live.debounce.500ms="form.username" autocomplete="off" />
|
<flux:label>Nama Pengguna <span class="text-red-500 ms-1">*</span></flux:label>
|
||||||
|
|
||||||
<flux:input label="Kata Sandi" placeholder="Masukkan kata sandi" type="password"
|
<flux:input placeholder="pangestu" wire:model.live="form.username" autocomplete="off" />
|
||||||
wire:model.live.debounce.500ms="form.password" autocomplete="off" viewable />
|
|
||||||
|
<flux:error name="form.username" />
|
||||||
|
</flux:field>
|
||||||
|
|
||||||
|
<flux:field>
|
||||||
|
<flux:label>Kata Sandi <span class="text-red-500 ms-1">*</span></flux:label>
|
||||||
|
|
||||||
|
<flux:input placeholder="********" type="password" wire:model.live="form.password"
|
||||||
|
autocomplete="off" viewable />
|
||||||
|
|
||||||
|
<flux:error name="form.password" />
|
||||||
|
</flux:field>
|
||||||
</div>
|
</div>
|
||||||
@endif
|
@endif
|
||||||
|
|
||||||
@if ($currentStep === 2)
|
@if ($currentStep === 2)
|
||||||
<div class="flex flex-col gap-6">
|
<div class="flex flex-col gap-6">
|
||||||
<flux:input label="Nama" placeholder="Masukkan nama" wire:model.live.debounce.500ms="form.name"
|
<flux:field>
|
||||||
autofocus autocomplete="off" />
|
<flux:label>Nama <span class="text-red-500 ms-1">*</span></flux:label>
|
||||||
|
|
||||||
<flux:input label="Nomor Telepon" placeholder="Masukkan nomor telepon" mask="9999 9999 99999"
|
<flux:input placeholder="John Doe" wire:model.live="form.name" autofocus autocomplete="off" />
|
||||||
wire:model.live.debounce.500ms="form.phone_number" autocomplete="off" />
|
|
||||||
|
|
||||||
<flux:radio.group wire:model.live="form.gender" variant="buttons" class="w-full *:flex-1"
|
<flux:error name="form.name" />
|
||||||
label="Jenis Kelamin">
|
</flux:field>
|
||||||
@foreach (\App\Enums\Gender::cases() as $gender)
|
|
||||||
<flux:radio value="{{ $gender->value }}">
|
<flux:field>
|
||||||
{{ $gender->label() }}
|
<flux:label>Nomor Telepon <span class="text-red-500 ms-1">*</span></flux:label>
|
||||||
</flux:radio>
|
|
||||||
@endforeach
|
<flux:input placeholder="0821 xxxx xxxx" mask="9999 9999 99999"
|
||||||
</flux:radio.group>
|
wire:model.live="form.phone_number" autocomplete="off" />
|
||||||
|
|
||||||
|
<flux:error name="form.phone_number" />
|
||||||
|
</flux:field>
|
||||||
|
|
||||||
|
<flux:field>
|
||||||
|
<flux:label>Jenis Kelamin <span class="text-red-500 ms-1">*</span></flux:label>
|
||||||
|
|
||||||
|
<flux:radio.group wire:model.live="form.gender" variant="buttons" class="w-full *:flex-1">
|
||||||
|
@foreach (\App\Enums\Gender::cases() as $gender)
|
||||||
|
<flux:radio value="{{ $gender->value }}">
|
||||||
|
{{ $gender->label() }}
|
||||||
|
</flux:radio>
|
||||||
|
@endforeach
|
||||||
|
</flux:radio.group>
|
||||||
|
|
||||||
|
<flux:error name="form.gender" />
|
||||||
|
</flux:field>
|
||||||
|
|
||||||
<flux:input label="Kode Referral" placeholder="Masukkan kode referral"
|
<flux:input label="Kode Referral" placeholder="Masukkan kode referral"
|
||||||
wire:model.live.debounce.500ms="form.referral_code" autocomplete="off" />
|
wire:model.live="form.referral_code" autocomplete="off" />
|
||||||
</div>
|
</div>
|
||||||
@endif
|
@endif
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user