Files
zellyy-finance/src/components/transaction/TransactionAmount.tsx
gpt-engineer-app[bot] cc0af1aee0 Fix rendering issue
Addresses a problem where the screen was not rendering correctly.
2025-03-15 10:27:42 +00:00

28 lines
714 B
TypeScript

import React from 'react';
import { ArrowDownIcon } from 'lucide-react';
interface TransactionAmountProps {
amount: number;
}
const TransactionAmount: React.FC<TransactionAmountProps> = ({ amount }) => {
// 금액을 한국 통화 형식으로 포맷팅 (소수점 제거)
const formattedAmount = new Intl.NumberFormat('ko-KR', {
style: 'currency',
currency: 'KRW',
maximumFractionDigits: 0
}).format(Math.abs(amount));
return (
<div className="flex items-center gap-1">
<ArrowDownIcon size={12} className="text-neuro-income" />
<span className="font-medium text-neuro-income">
{formattedAmount}
</span>
</div>
);
};
export default TransactionAmount;