Skip to content

🏗️📦feat: copy auth components slice into frontend/apps/web/ #65

@sotoJ24

Description

@sotoJ24

Issue Summary

Copy the authentication components from frontend-SafeTrust/src/components/auth/ into apps/web/src/components/auth/. Update import paths only. Do not modify logic.

Type of Issue

  • Feature Request

Depends on

Issue 1 must be merged first.

Source files (from frontend-SafeTrust)

src/components/auth/
├── Login.tsx                   ← copy as-is, update imports
├── Register.tsx                ← copy as-is, update imports
├── ForgotPasswordForm.tsx      ← copy
├── NewPassword.tsx             ← copy
├── ResetPasswordForm.tsx       ← copy
├── VerifyEmail.tsx             ← copy
├── InvalidResetToken.tsx       ← copy
├── ui/
│   └── Illustration.tsx        ← copy
└── wallet/
    ├── hooks/
    │   └── multi-wallet.hook.ts   ← copy
    └── components/
        ├── MainWalletSelectionModal.tsx
        ├── WalletSelectionModal.tsx
        └── MetaMaskWalletModal.tsx

Target location in dApp-SafeTrust

apps/web/src/components/auth/   ← exact mirror of source

Import path rules

The following import aliases must be updated to match apps/web/:

Original import Updated import
@/components/ui/button @/components/ui/button (same — ui is local)
@/core/store/data @/core/store/data (copy store in Issue 5)
@/components/auth/wallet/... @/components/auth/wallet/... (same structure)

For any import that references a file NOT copied in this batch, replace with a stub:

// TODO: wire in Batch 2 — <original import path>
const ComponentName = () => null;

Key file: Login.tsx

Looking at the actual Login.tsx source, it imports:

  • next/link ✅ available
  • next/image ✅ available
  • lucide-react ✅ in package.json
  • @/components/ui/button ← needs ui/ components (Issue 3)
  • @/components/ui/checkbox ← same
  • @/components/ui/input ← same
  • @/components/ui/label ← same
  • @/components/ui/separator ← same
  • @/components/auth/ui/Illustration ✅ copied in this issue
  • @/core/store/data ← stub for now (Issue 5)
  • next/navigation ✅ available
  • ./wallet/hooks/multi-wallet.hook ✅ copied in this issue
  • ./wallet/components/MainWalletSelectionModal ✅ copied in this issue
  • ./wallet/components/WalletSelectionModal ✅ copied in this issue
  • ./wallet/components/MetaMaskWalletModal ✅ copied in this issue

Acceptance Criteria

  • All files from frontend-SafeTrust/src/components/auth/ exist in apps/web/src/components/auth/
  • No TypeScript errors on files that have all their imports resolved
  • Files with unresolved imports have // TODO: wire in Batch 2 stubs instead of broken imports
  • No logic changes — only import path updates permitted
  • pnpm build --filter @safetrust/web does not fail due to syntax errors in copied files

References


Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions