Skip to content

Commit fcb5469

Browse files
committed
[#130] refactor: UI수정
1 parent e66a7ad commit fcb5469

File tree

2 files changed

+13
-5
lines changed

2 files changed

+13
-5
lines changed

src/components/FloatingBox/BookingButton.tsx

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,27 +1,32 @@
11
import React from 'react';
2+
import { cn } from '@/lib/utils';
23

34
interface BookingButtonProps {
45
onClick: () => void;
56
children: React.ReactNode;
67
disabled?: boolean;
78
onBooking?: boolean;
9+
className?: string;
810
}
911

1012
export default function BookingButton({
1113
onClick,
1214
children,
1315
disabled = false,
1416
onBooking = false,
17+
className = '',
1518
}: BookingButtonProps) {
1619
return (
1720
<button
1821
onClick={onClick}
1922
disabled={disabled || onBooking}
20-
className={`relative mt-4 mb-6 w-full max-w-sm rounded-lg py-10 font-medium transition-colors ${
23+
className={cn(
24+
'relative mt-4 mb-6 w-full max-w-sm rounded-lg py-10 font-medium transition-colors',
2125
disabled || onBooking
2226
? 'cursor-not-allowed bg-gray-300 text-gray-500'
23-
: 'bg-green-800 text-white hover:bg-green-900'
24-
}`}
27+
: 'bg-green-800 text-white hover:bg-green-900',
28+
className,
29+
)}
2530
>
2631
{onBooking ? (
2732
<div className='flex items-center justify-center gap-2'>

src/ui/MobileBookingModal.tsx

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ export default function MobileModal({
8080
<div className='flex min-h-400 flex-col items-center justify-center gap-20'>
8181
<div>
8282
<p className='font-bold'>
83-
날짜 및 시간 {selectedDate?.toLocaleDateString()}
83+
날짜 및 시간 {selectedDate?.toLocaleDateString()}/
8484
{selectedTime}
8585
</p>
8686
</div>
@@ -111,7 +111,10 @@ export default function MobileModal({
111111
다음
112112
</button>
113113
) : (
114-
<BookingButton onClick={() => handleConfirm()}>
114+
<BookingButton
115+
className='flex-1 px-10 py-10'
116+
onClick={() => handleConfirm()}
117+
>
115118
확인
116119
</BookingButton>
117120
)}

0 commit comments

Comments
 (0)