website refactor
This commit is contained in:
@@ -1,26 +1,17 @@
|
||||
/**
|
||||
* Forgot Password View Data Builder
|
||||
*
|
||||
*
|
||||
* Transforms ForgotPasswordPageDTO into ViewData for the forgot password template.
|
||||
* Deterministic, side-effect free, no business logic.
|
||||
*/
|
||||
|
||||
import { ForgotPasswordPageDTO } from '@/lib/services/auth/types/ForgotPasswordPageDTO';
|
||||
|
||||
export interface ForgotPasswordViewData {
|
||||
returnTo: string;
|
||||
showSuccess: boolean;
|
||||
successMessage?: string;
|
||||
magicLink?: string;
|
||||
formState: any; // Will be managed by client component
|
||||
isSubmitting: boolean;
|
||||
submitError?: string;
|
||||
}
|
||||
import { ForgotPasswordViewData } from './types/ForgotPasswordViewData';
|
||||
|
||||
export class ForgotPasswordViewDataBuilder {
|
||||
static build(data: ForgotPasswordPageDTO): ForgotPasswordViewData {
|
||||
static build(apiDto: ForgotPasswordPageDTO): ForgotPasswordViewData {
|
||||
return {
|
||||
returnTo: data.returnTo,
|
||||
returnTo: apiDto.returnTo,
|
||||
showSuccess: false,
|
||||
formState: {
|
||||
fields: {
|
||||
|
||||
Reference in New Issue
Block a user