improve code
This commit is contained in:
@@ -36,14 +36,14 @@
|
||||
@section('content')
|
||||
<canvas class="confetti-canvas" id="confetti"></canvas>
|
||||
|
||||
<main class="flex-grow flex flex-col items-center justify-center px-container-padding pt-24 pb-32 mt-16 w-full">
|
||||
<main class="flex-grow flex flex-col items-center justify-center px-container-padding pt-24 pb-32 mt-16 w-full max-w-md mx-auto">
|
||||
<!-- Success Indicator -->
|
||||
<div class="mb-xl relative">
|
||||
<div class="w-24 h-24 bg-primary-fixed rounded-full flex items-center justify-center text-primary-container shadow-[0_0_40px_rgba(0,105,72,0.2)]">
|
||||
<span class="material-symbols-outlined !text-5xl" style="font-variation-settings: 'FILL' 1;">check_circle</span>
|
||||
<x-icon name="check_circle" class="w-12 h-12 text-primary-container" />
|
||||
</div>
|
||||
<!-- Decorative Sparks -->
|
||||
<div class="absolute -top-2 -right-2 text-primary opacity-50"><span class="material-symbols-outlined !text-xl">auto_awesome</span></div>
|
||||
<div class="absolute -top-2 -right-2 text-primary opacity-50"><x-icon name="auto_awesome" class="w-5 h-5" /></div>
|
||||
</div>
|
||||
|
||||
<!-- Typography Block -->
|
||||
@@ -60,9 +60,17 @@
|
||||
<span class="font-mono text-4xl font-bold text-primary tracking-widest" id="couponCode">{{ $code }}</span>
|
||||
</div>
|
||||
<button class="flex items-center gap-2 text-primary font-label-md text-label-md hover:bg-primary-container/10 px-md py-sm rounded-full transition-colors active:scale-95" onclick="copyCode()">
|
||||
<span class="material-symbols-outlined" id="copyIcon">content_copy</span>
|
||||
<span id="copyIcon" class="inline-flex">
|
||||
<x-icon name="content_copy" class="w-5 h-5" data-icon="content_copy" />
|
||||
</span>
|
||||
<span id="copyText">Kody göçür</span>
|
||||
</button>
|
||||
<template id="icon-check">
|
||||
<x-icon name="check" class="w-5 h-5" />
|
||||
</template>
|
||||
<template id="icon-content_copy">
|
||||
<x-icon name="content_copy" class="w-5 h-5" />
|
||||
</template>
|
||||
</div>
|
||||
<!-- Shadow Depth -->
|
||||
<div class="absolute -bottom-4 left-1/2 -translate-x-1/2 w-[80%] h-4 bg-primary/10 blur-xl rounded-full -z-10"></div>
|
||||
@@ -77,7 +85,7 @@
|
||||
|
||||
<!-- Info Card -->
|
||||
<div class="mt-2xl w-full max-w-sm bg-secondary-container/30 border border-secondary-container rounded-lg p-md flex gap-md items-start">
|
||||
<span class="material-symbols-outlined text-secondary">info</span>
|
||||
<x-icon name="info" class="w-6 h-6 text-secondary shrink-0" />
|
||||
<p class="font-body-sm text-body-sm text-on-secondary-container">
|
||||
Bu kupon diňe öňümizdäki 24 sagadyň dowamynda hereket edýär. Arzanladyşdan peýdalanmak üçin töleg wagtynda ulanmagy ýatdan çykarmaň.
|
||||
</p>
|
||||
@@ -151,11 +159,11 @@
|
||||
const btnIcon = document.getElementById('copyIcon');
|
||||
|
||||
btnText.innerText = 'Göçürildi!';
|
||||
btnIcon.innerText = 'check';
|
||||
btnIcon.innerHTML = document.getElementById('icon-check').innerHTML;
|
||||
|
||||
setTimeout(() => {
|
||||
btnText.innerText = 'Kody göçür';
|
||||
btnIcon.innerText = 'content_copy';
|
||||
btnIcon.innerHTML = document.getElementById('icon-content_copy').innerHTML;
|
||||
}, 2000);
|
||||
}
|
||||
|
||||
|
||||
@@ -34,7 +34,7 @@
|
||||
<form action="{{ route('verification.send') }}" method="POST" class="flex-grow flex flex-col" id="phone-form">
|
||||
@csrf
|
||||
<div class="space-y-md flex-grow">
|
||||
<div class="group relative flex items-center bg-surface-container-lowest border border-outline-variant rounded-DEFAULT h-16 px-md transition-all duration-300 focused-input-glow focus-within:border-primary">
|
||||
<div class="group relative flex items-center bg-surface-container-lowest border border-outline-variant rounded h-16 px-md transition-all duration-300 focused-input-glow focus-within:border-primary">
|
||||
<!-- Country Code Selector (Simulated) -->
|
||||
<button type="button" class="flex items-center gap-xs pr-md border-r border-outline-variant mr-md hover:bg-surface-container-low transition-colors h-10 rounded-sm">
|
||||
<span class="font-label-md text-label-md text-on-surface">+993</span>
|
||||
@@ -49,8 +49,8 @@
|
||||
<p class="text-error text-sm">{{ $message }}</p>
|
||||
@enderror
|
||||
|
||||
<div class="flex items-start gap-sm bg-secondary-container/30 p-md rounded-DEFAULT border border-secondary-container">
|
||||
<span class="material-symbols-outlined text-on-secondary-container mt-0.5" data-icon="info">info</span>
|
||||
<div class="flex items-start gap-sm bg-secondary-container/30 p-md rounded border border-secondary-container">
|
||||
<x-icon name="info" class="w-6 h-6 text-on-secondary-container mt-0.5" />
|
||||
<p class="font-body-sm text-body-sm text-on-secondary-container">
|
||||
Tassyklaýyş maksady bilen size bir SMS kod iberiler.
|
||||
</p>
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
@section('header-back')
|
||||
<a href="{{ route('verification.index') }}" class="hover:opacity-80 transition-opacity active:scale-95 transition-transform flex items-center justify-center p-2 rounded-full">
|
||||
<span class="material-symbols-outlined text-primary" data-icon="arrow_back">arrow_back</span>
|
||||
<x-icon name="arrow_back" class="w-6 h-6 text-primary" />
|
||||
</a>
|
||||
@endsection
|
||||
|
||||
@@ -29,7 +29,7 @@
|
||||
<!-- Hero Content -->
|
||||
<div class="mt-2xl text-center">
|
||||
<div class="inline-flex items-center justify-center w-20 h-20 rounded-full bg-secondary-container mb-lg">
|
||||
<span class="material-symbols-outlined text-primary text-4xl" data-icon="app_registration">app_registration</span>
|
||||
<x-icon name="app_registration" class="w-10 h-10 text-primary" />
|
||||
</div>
|
||||
<h2 class="font-headline-xl text-headline-xl text-on-surface mb-sm">Belgiňizi tassyklaň</h2>
|
||||
|
||||
@@ -57,10 +57,10 @@
|
||||
|
||||
<!-- OTP Inputs -->
|
||||
<div class="mt-2xl flex justify-center gap-md" id="otp-container">
|
||||
<input autocomplete="one-time-code" class="otp-input w-16 h-20 text-center font-otp-digit text-otp-digit rounded-DEFAULT border-outline-variant bg-surface-container-lowest focus:border-primary focus:ring-0 transition-all" inputmode="numeric" maxlength="1" type="text"/>
|
||||
<input class="otp-input w-16 h-20 text-center font-otp-digit text-otp-digit rounded-DEFAULT border-outline-variant bg-surface-container-lowest focus:border-primary focus:ring-0 transition-all" inputmode="numeric" maxlength="1" type="text"/>
|
||||
<input class="otp-input w-16 h-20 text-center font-otp-digit text-otp-digit rounded-DEFAULT border-outline-variant bg-surface-container-lowest focus:border-primary focus:ring-0 transition-all" inputmode="numeric" maxlength="1" type="text"/>
|
||||
<input class="otp-input w-16 h-20 text-center font-otp-digit text-otp-digit rounded-DEFAULT border-outline-variant bg-surface-container-lowest focus:border-primary focus:ring-0 transition-all" inputmode="numeric" maxlength="1" type="text"/>
|
||||
<input autocomplete="one-time-code" class="otp-input w-16 h-20 text-center font-otp-digit text-otp-digit rounded border-outline-variant bg-surface-container-lowest focus:border-primary focus:ring-0 transition-all" inputmode="numeric" maxlength="1" type="text"/>
|
||||
<input class="otp-input w-16 h-20 text-center font-otp-digit text-otp-digit rounded border-outline-variant bg-surface-container-lowest focus:border-primary focus:ring-0 transition-all" inputmode="numeric" maxlength="1" type="text"/>
|
||||
<input class="otp-input w-16 h-20 text-center font-otp-digit text-otp-digit rounded border-outline-variant bg-surface-container-lowest focus:border-primary focus:ring-0 transition-all" inputmode="numeric" maxlength="1" type="text"/>
|
||||
<input class="otp-input w-16 h-20 text-center font-otp-digit text-otp-digit rounded border-outline-variant bg-surface-container-lowest focus:border-primary focus:ring-0 transition-all" inputmode="numeric" maxlength="1" type="text"/>
|
||||
</div>
|
||||
|
||||
<!-- Actions -->
|
||||
@@ -81,9 +81,9 @@
|
||||
</div>
|
||||
|
||||
<!-- Info Card -->
|
||||
<div class="mt-auto mb-xl p-md rounded-DEFAULT border border-outline-variant bg-surface-container-low">
|
||||
<div class="mt-auto mb-xl p-md rounded border border-outline-variant bg-surface-container-low">
|
||||
<div class="flex gap-sm">
|
||||
<span class="material-symbols-outlined text-on-surface-variant" data-icon="info">info</span>
|
||||
<x-icon name="info" class="w-6 h-6 text-on-surface-variant" />
|
||||
<p class="font-body-sm text-body-sm text-on-surface-variant">
|
||||
SMS kody 2 minutdan 5 minuda çenli baryp biler, garaşmagyňyzy Sizden haýyş edýäris.
|
||||
</p>
|
||||
|
||||
Reference in New Issue
Block a user