[Object Object] 표시 오류 수정: Intl.NumberFormat 사용

This commit is contained in:
Jay Sheen
2025-10-30 10:19:25 +09:00
parent 3dbd6b4dda
commit 2553aca4de
17 changed files with 47 additions and 47 deletions

View File

@@ -22,7 +22,7 @@ export const AmountInfoWrap = ({
<li className="kv-row">
<span className="k">{t('settlement.totalTransactionAmount')}</span>
<span className="v">
{t('home.money', { value: <NumericFormat value={ amountInfo?.totalTransactionAmount } thousandSeparator displayType="text" /> })}
{t('home.money', { value: new Intl.NumberFormat('en-US').format(amountInfo?.totalTransactionAmount || 0) })}
<NumericFormat
value={ amountInfo?.totalTransactionCount }
thousandSeparator
@@ -35,7 +35,7 @@ export const AmountInfoWrap = ({
<li>
<span>·&nbsp;&nbsp;{t('settlement.creditCard')}</span>
<span className="unset-child-span">
{t('home.money', { value: <NumericFormat value={ amountInfo?.creditCardAmount } thousandSeparator displayType="text" /> })}
{t('home.money', { value: new Intl.NumberFormat('en-US').format(amountInfo?.creditCardAmount || 0) })}
<NumericFormat
value={ amountInfo?.creditCardCount }
thousandSeparator
@@ -48,7 +48,7 @@ export const AmountInfoWrap = ({
<li>
<span>·&nbsp;&nbsp;{t('settlement.accountTransfer')}</span>
<span className="unset-child-span">
{t('home.money', { value: <NumericFormat value={ amountInfo?.accountTransferAmount } thousandSeparator displayType="text" /> })}
{t('home.money', { value: new Intl.NumberFormat('en-US').format(amountInfo?.accountTransferAmount || 0) })}
<NumericFormat
value={ amountInfo?.accountTransferCount }
thousandSeparator
@@ -159,49 +159,49 @@ export const AmountInfoWrap = ({
<li className="kv-row">
<span className="k">{t('settlement.transactionAmount')}</span>
<span className="v">
{t('home.money', { value: <NumericFormat value={ amountInfo?.transactionAmount } thousandSeparator displayType="text" /> })}
{t('home.money', { value: new Intl.NumberFormat('en-US').format(amountInfo?.transactionAmount || 0) })}
</span>
</li>
<li className="kv-row">
<span className="k">{t('settlement.paymentFee')}</span>
<span className="v">
{t('home.money', { value: <NumericFormat value={ amountInfo?.paymentFee } thousandSeparator displayType="text" /> })}
{t('home.money', { value: new Intl.NumberFormat('en-US').format(amountInfo?.paymentFee || 0) })}
</span>
</li>
<li className="kv-row">
<span className="k">{t('settlement.escrowFee')}</span>
<span className="v">
{t('home.money', { value: <NumericFormat value={ amountInfo?.escrowFee } thousandSeparator displayType="text" /> })}
{t('home.money', { value: new Intl.NumberFormat('en-US').format(amountInfo?.escrowFee || 0) })}
</span>
</li>
<li className="kv-row">
<span className="k">{t('settlement.authFee')}</span>
<span className="v">
{t('home.money', { value: <NumericFormat value={ amountInfo?.authFee } thousandSeparator displayType="text" /> })}
{t('home.money', { value: new Intl.NumberFormat('en-US').format(amountInfo?.authFee || 0) })}
</span>
</li>
<li className="kv-row">
<span className="k">VAT</span>
<span className="v">
{t('home.money', { value: <NumericFormat value={ amountInfo?.vatFee } thousandSeparator displayType="text" /> })}
{t('home.money', { value: new Intl.NumberFormat('en-US').format(amountInfo?.vatFee || 0) })}
</span>
</li>
<li className="kv-row">
<span className="k">{t('settlement.expectedSettlementAmount')}</span>
<span className="v">
{t('home.money', { value: <NumericFormat value={ amountInfo?.settlementAmount } thousandSeparator displayType="text" /> })}
{t('home.money', { value: new Intl.NumberFormat('en-US').format(amountInfo?.settlementAmount || 0) })}
</span>
</li>
<li className="kv-row">
<span className="k">{t('settlement.preSettlementCancelOffset')}</span>
<span className="v">
{t('home.money', { value: <NumericFormat value={ amountInfo?.preSettlementCancelOffset } thousandSeparator displayType="text" /> })}
{t('home.money', { value: new Intl.NumberFormat('en-US').format(amountInfo?.preSettlementCancelOffset || 0) })}
</span>
</li>
<li className="kv-row bolder">
<span className="k">{t('settlement.settlementAmount')}</span>
<span className="v">
{t('home.money', { value: <NumericFormat value={ amountInfo?.finalSettlementAmount } thousandSeparator displayType="text" /> })}
{t('home.money', { value: new Intl.NumberFormat('en-US').format(amountInfo?.finalSettlementAmount || 0) })}
</span>
</li>
</ul>

View File

@@ -65,7 +65,7 @@ export const ListItem = ({
}
</div>
<div className="transaction-amount">
{t('home.money', { value: <NumericFormat value={ settlementAmount || transactionAmount } thousandSeparator displayType="text" /> })}
{t('home.money', { value: new Intl.NumberFormat('en-US').format(settlementAmount || transactionAmount || 0) })}
</div>
</div>
</>

View File

@@ -391,7 +391,7 @@ export const ListWrap = ({
<div className="summary-label label">{t('settlement.settlementAmount')}</div>
<div className="summary-amount divTop">
<span className="amount-text">
{t('home.money', { value: <NumericFormat value={ settlementAmount } thousandSeparator displayType="text" /> })}
{t('home.money', { value: new Intl.NumberFormat('en-US').format(settlementAmount || 0) })}
</span>
<button
onClick={ () => setIsOpenSummary(!isOpenSummary) }