Skip to content

Commit

Permalink
Merge pull request #318 from ssu-student-union/refactor/#316_onboard_…
Browse files Browse the repository at this point in the history
…input

Refactor/#316 onboard input
  • Loading branch information
jongse7 authored Nov 6, 2024
2 parents af6599d + fe47f6f commit 541d939
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion src/components/ui/button.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ const Button = React.forwardRef<HTMLButtonElement, ButtonProps>(
({ className, variant, size, isDisabled = false, asChild = false, ...props }, ref) => {
const Comp = asChild ? Slot : 'button';
return (
<Comp className={cn(buttonVariants({ variant, size, className }))} ref={ref} disabled={isDisabled} {...props} />
<Comp className={cn(buttonVariants({ className, variant, size }))} ref={ref} disabled={isDisabled} {...props} />
);
}
);
Expand Down
12 changes: 6 additions & 6 deletions src/pages/general/containers/GeneralRegisterSection.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -157,15 +157,15 @@ export function GeneralRegisterSection({ subSection1, buttonSection }: LoginForm

return (
<div className="flex min-h-screen items-center justify-center">
<div className="flex w-full max-w-md flex-col items-center p-4">
<div className="flex w-full max-w-md flex-col items-center justify-center p-4">
<div className="pb-4 text-2xl font-bold not-italic leading-[normal] text-[rgb(0,0,0)]">{subSection1}</div>
<form noValidate onSubmit={handleSubmit(onSubmit)}>
{isScouncilPath ? (
<>
<Input
type="text"
placeholder="아이디"
className="w-[420px]"
className="w-[420px] xs:w-[250px] sm:w-[250px]"
{...register('accountId', {
required: '아이디는 필수 입력입니다.',
})}
Expand All @@ -180,7 +180,7 @@ export function GeneralRegisterSection({ subSection1, buttonSection }: LoginForm
<Input
type="password"
placeholder="비밀번호"
className="mt-4"
className="mt-4 xs:w-[250px] sm:w-[250px]"
{...register('password', {
required: '비밀번호는 필수 입력입니다.',
})}
Expand All @@ -199,7 +199,7 @@ export function GeneralRegisterSection({ subSection1, buttonSection }: LoginForm
<Input
type="text"
placeholder="이름"
className="w-[420px]"
className="w-[420px] xs:w-[250px] sm:w-[250px]"
{...register('name', {
required: '이름은 필수 입력입니다.',
})}
Expand All @@ -215,7 +215,7 @@ export function GeneralRegisterSection({ subSection1, buttonSection }: LoginForm
<Input
type="text"
placeholder="학번"
className="mt-4"
className="mt-4 xs:w-[250px] sm:w-[250px]"
{...register('studentId', {
required: '학번은 필수 입력입니다.',
})}
Expand Down Expand Up @@ -296,7 +296,7 @@ export function GeneralRegisterSection({ subSection1, buttonSection }: LoginForm
disabled={isSubmitting || isButtonDisabled}
variant="default"
size="default"
className={`mt-4 w-[420px] ${isSubmitting || isButtonDisabled ? 'bg-gray-400' : ''}`}
className={`mt-4 w-[420px] xs:w-[250px] sm:w-[250px] ${isSubmitting || isButtonDisabled ? 'bg-gray-400' : ''}`}
>
{buttonSection}
</Button>
Expand Down

0 comments on commit 541d939

Please sign in to comment.