Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 9 additions & 4 deletions apps/web/src/components/auction-detail/bid-form/input.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ import { Button } from '@/components/ui/button';

import { useAuctionDetail } from '@/hooks/queries/auction';

import { cn } from '@/lib/cn';
import { formatCurrency, formatCurrencyWithUnit, formatToKoreanUnit } from '@/lib/utils/price';

import { BidInputProps } from '@/types/bid';
Expand All @@ -15,7 +16,7 @@ const bidInputWrapper = tv({
base: 'transition-all duration-600 overflow-hidden px-1',
variants: {
open: {
true: 'pt-2 max-h-[150px] translate-y-0',
true: 'pt-2 max-h-[160px] translate-y-0',
false: 'max-h-0 translate-y-4 pointer-events-none',
},
},
Expand Down Expand Up @@ -76,21 +77,25 @@ const BidFormInput = ({
return (
<div className={bidInputWrapper({ open: isBidInputOpen })}>
<div className="h-25 flex w-full flex-col items-start justify-center gap-2">
<label htmlFor="price">
<label htmlFor="price" className="flex items-center gap-1">
<p className="font-medium">희망입찰가</p>
<span className="text-xs text-neutral-500">
(입찰 단위: <strong>{formatCurrency(minBidUnit || 0)}</strong>원)
</span>
</label>
<div className="shadow-xs flex h-14 w-full min-w-0 items-center justify-between rounded-sm border bg-transparent p-1 text-base text-neutral-400 focus-within:border-neutral-400 focus-within:ring-[2px] focus-within:ring-neutral-400/50 md:text-sm [&>svg]:h-5 [&>svg]:w-5">
<div
className={cn(
`shadow-xs flex h-14 w-full min-w-0 items-center justify-between rounded-sm border bg-transparent p-1 text-base text-neutral-400 focus-within:border-neutral-400 focus-within:ring-[2px] focus-within:ring-neutral-400/50 md:text-sm [&>svg]:h-5 [&>svg]:w-5`
)}
>
<div className="flex items-center gap-2 pl-2">
<UserRound />
<input
id="price"
value={bidPrice ?? defaultBidPrice}
placeholder={placeholder}
onChange={handleChange}
className="aria-invalid:ring-danger-700/20 aria-invalid:border-danger-700 selection:text-primary-500 w-[270px] text-black placeholder:text-neutral-400 focus:shadow-none focus:outline-none disabled:pointer-events-none disabled:cursor-not-allowed disabled:opacity-50"
className="aria-invalid:ring-danger-700/20 aria-invalid:border-danger-700 selection:text-primary-500 w-full text-black placeholder:text-neutral-400 focus:shadow-none focus:outline-none disabled:pointer-events-none disabled:cursor-not-allowed disabled:opacity-50"
/>
</div>
<button
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ const BidTable = ({ auctionId, initialBids }: BidTableProps) => {
<BidTableHead />
<div className="relative">
<span className="w-7.5 absolute flex h-full items-center justify-center text-neutral-400">
<i className="bg-primary-100 h-9/10 block w-1"></i>
<i className="bg-primary-100 h-8/10 block w-1"></i>
</span>
<ul ref={animationParent} className="space-y-2">
{sortedBids.map((item) => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ const BidderAvatar = ({
src={profileImg}
alt={nickname}
size={'small'}
className={authorStyle({ author: isAuthor })}
className={`border-1 border-primary-100 ${authorStyle({ author: isAuthor })}`}
/>
);
};
Expand Down
2 changes: 1 addition & 1 deletion apps/web/src/components/auction-detail/bid-table/row.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ const BidTableRow = ({ item }: { item: BidType }) => {
/>
<div
className={cn(
'ml-3 flex w-full rounded-sm bg-white py-2.5 text-sm text-neutral-600 opacity-90',
'border-1 border-primary-100 ml-3 flex w-full rounded-sm bg-white py-2.5 text-sm text-neutral-600 opacity-90',
Comment thread
geumyoung00 marked this conversation as resolved.
isAuthor &&
'border-1 border-primary-500 text-primary-600 shadow-primary-300 font-bold opacity-100 shadow-sm'
)}
Expand Down
Loading