Files
FrontOffice/src/FrontOffice.Main/Shared/AuthDialog.razor
T
masoodafar-web 6db83ccd90
Build and Deploy to Kubernetes / build-and-deploy (push) Failing after 4m55s
feat: full FrontOffice updates - discount store, blog, payment gateway, UI improvements
- Discount store pages (products, cart, orders, order detail)
- Blog pages and services
- Payment gateway callback page
- AppImage component, EmptyState, LoadingState, PageHeader
- DiscountCartService, DiscountOrderService, DiscountProductService
- BlogCategoryService, BlogPostService, SitePageService, ImageCacheService
- PhoneVerifyForm component
- Profile Hub page
- UI/UX improvements across all pages
- landing.js for homepage
- Config and routing updates
2026-02-16 00:51:39 +03:30

102 lines
5.0 KiB
Plaintext

@if (InlineMode)
{
@* Inline rendering without MudDialog wrapper *@
<div class="auth-dialog-content">
<MudStack Spacing="3" AlignItems="AlignItems.Center" Class="mb-4">
<MudAvatar Size="Size.Large" Color="Color.Primary" Variant="Variant.Filled">
<MudIcon Icon="@(_currentStep == AuthStep.Phone ? Icons.Material.Outlined.PhoneAndroid : Icons.Material.Outlined.LockOpen)" Size="Size.Large" />
</MudAvatar>
<MudText Typo="Typo.h5">@GetDialogTitle()</MudText>
</MudStack>
<PhoneVerifyForm @ref="_phoneVerifyForm"
CurrentStep="_currentStep"
PhoneRequest="_phoneRequest"
VerifyRequest="_verifyRequest"
CaptchaCode="@_captchaCode"
CaptchaInput="@_captchaInput"
CaptchaInputChanged="@(v => _captchaInput = v)"
OnRefreshCaptcha="GenerateCaptcha"
IsBusy="_isBusy"
ErrorMessage="@_errorMessage"
InfoMessage="@_infoMessage"
PhoneNumber="@_phoneNumber"
ResendRemaining="_resendRemaining"
OnChangePhone="ChangePhoneAsync"
OnResendOtp="ResendOtpAsync" />
</div>
}
else
{
<MudDialog Class="auth-dialog-wrapper">
<DialogContent>
<div class="auth-dialog-content">
<MudStack Spacing="2" AlignItems="AlignItems.Center" Class="mb-4 pt-2">
<MudAvatar Size="Size.Large" Color="Color.Primary" Variant="Variant.Filled">
<MudIcon Icon="@(_currentStep == AuthStep.Phone ? Icons.Material.Outlined.PhoneAndroid : Icons.Material.Outlined.LockOpen)" Size="Size.Large" />
</MudAvatar>
<MudText Typo="Typo.h5" Align="Align.Center">@GetDialogTitle()</MudText>
</MudStack>
<PhoneVerifyForm @ref="_phoneVerifyForm"
CurrentStep="_currentStep"
PhoneRequest="_phoneRequest"
VerifyRequest="_verifyRequest"
CaptchaCode="@_captchaCode"
CaptchaInput="@_captchaInput"
CaptchaInputChanged="@(v => _captchaInput = v)"
OnRefreshCaptcha="GenerateCaptcha"
IsBusy="_isBusy"
ErrorMessage="@_errorMessage"
InfoMessage="@_infoMessage"
PhoneNumber="@_phoneNumber"
ResendRemaining="_resendRemaining"
OnChangePhone="ChangePhoneAsync"
OnResendOtp="ResendOtpAsync" />
<MudStack Class="mt-4" Spacing="2">
@if (_currentStep == AuthStep.Phone)
{
<MudButton Variant="Variant.Filled"
Color="Color.Primary"
OnClick="SendOtpAsync"
Disabled="_isBusy"
Class="rounded-lg"
FullWidth="true"
Size="Size.Large">
@if (_isBusy)
{
<MudProgressCircular Size="Size.Small" Indeterminate="true" Class="me-2" />
}
ارسال رمز پویا
</MudButton>
}
else if (_currentStep == AuthStep.Verify)
{
<MudButton Variant="Variant.Filled"
Color="Color.Primary"
OnClick="VerifyOtpAsync"
Disabled="_isBusy || IsVerificationLocked"
Class="rounded-lg"
FullWidth="true"
Size="Size.Large">
@if (_isBusy)
{
<MudProgressCircular Size="Size.Small" Indeterminate="true" Class="me-2" />
}
تأیید و ورود
</MudButton>
}
@if (!HideCancelButton)
{
<MudButton Variant="Variant.Text"
OnClick="Cancel"
Disabled="_isBusy"
FullWidth="true">لغو
</MudButton>
}
</MudStack>
</div>
</DialogContent>
</MudDialog>
}