Forráskód Böngészése

refactor: move password-input component into custom component dir

satnaing 2 éve
szülő
commit
9b380011d3

+ 2 - 2
src/components/password-input.tsx → src/components/custom/password-input.tsx

@@ -1,7 +1,7 @@
 import * as React from 'react'
-import { cn } from '@/lib/utils'
-import { Button } from './custom/button'
 import { IconEye, IconEyeOff } from '@tabler/icons-react'
+import { Button } from './button'
+import { cn } from '@/lib/utils'
 
 export interface PasswordInputProps
   extends Omit<React.InputHTMLAttributes<HTMLInputElement>, 'type'> {}

+ 5 - 5
src/pages/auth/components/sign-up-form.tsx

@@ -1,9 +1,8 @@
 import { HTMLAttributes, useState } from 'react'
-import { cn } from '@/lib/utils'
-import { zodResolver } from '@hookform/resolvers/zod'
 import { useForm } from 'react-hook-form'
+import { zodResolver } from '@hookform/resolvers/zod'
+import { IconBrandFacebook, IconBrandGithub } from '@tabler/icons-react'
 import { z } from 'zod'
-import { Button } from '@/components/custom/button'
 import {
   Form,
   FormControl,
@@ -13,8 +12,9 @@ import {
   FormMessage,
 } from '@/components/ui/form'
 import { Input } from '@/components/ui/input'
-import { IconBrandFacebook, IconBrandGithub } from '@tabler/icons-react'
-import { PasswordInput } from '@/components/password-input'
+import { Button } from '@/components/custom/button'
+import { PasswordInput } from '@/components/custom/password-input'
+import { cn } from '@/lib/utils'
 
 interface SignUpFormProps extends HTMLAttributes<HTMLDivElement> {}
 

+ 2 - 2
src/pages/auth/components/user-auth-form.tsx

@@ -12,9 +12,9 @@ import {
   FormLabel,
   FormMessage,
 } from '@/components/ui/form'
-import { Button } from '@/components/custom/button'
 import { Input } from '@/components/ui/input'
-import { PasswordInput } from '@/components/password-input'
+import { Button } from '@/components/custom/button'
+import { PasswordInput } from '@/components/custom/password-input'
 import { cn } from '@/lib/utils'
 
 interface UserAuthFormProps extends HTMLAttributes<HTMLDivElement> {}