aboutsummaryrefslogtreecommitdiffstats
path: root/packages/website/ts/components/visual_order.tsx
diff options
context:
space:
mode:
authorFabio Berger <me@fabioberger.com>2018-03-11 05:43:13 +0800
committerFabio Berger <me@fabioberger.com>2018-03-11 05:43:13 +0800
commit4c08667a078ac9ca1ed5dc62d87a8cfe3b903741 (patch)
tree24e217526229e119908e963230f1290299229a9a /packages/website/ts/components/visual_order.tsx
parent4ac6b6828c30f2ec78bbea66b324c505641f24c3 (diff)
downloaddexon-0x-contracts-4c08667a078ac9ca1ed5dc62d87a8cfe3b903741.tar.gz
dexon-0x-contracts-4c08667a078ac9ca1ed5dc62d87a8cfe3b903741.tar.zst
dexon-0x-contracts-4c08667a078ac9ca1ed5dc62d87a8cfe3b903741.zip
Replace local PRECISION constants with global config.AMOUNT_DISPLAY_PRECISION
Diffstat (limited to 'packages/website/ts/components/visual_order.tsx')
-rw-r--r--packages/website/ts/components/visual_order.tsx5
1 files changed, 2 insertions, 3 deletions
diff --git a/packages/website/ts/components/visual_order.tsx b/packages/website/ts/components/visual_order.tsx
index ec2d47f39..3bf464e92 100644
--- a/packages/website/ts/components/visual_order.tsx
+++ b/packages/website/ts/components/visual_order.tsx
@@ -3,10 +3,9 @@ import * as _ from 'lodash';
import * as React from 'react';
import { Party } from 'ts/components/ui/party';
import { AssetToken, Token, TokenByAddress } from 'ts/types';
+import { configs } from 'ts/utils/configs';
import { utils } from 'ts/utils/utils';
-const PRECISION = 5;
-
interface VisualOrderProps {
makerAssetToken: AssetToken;
takerAssetToken: AssetToken;
@@ -67,7 +66,7 @@ export class VisualOrder extends React.Component<VisualOrderProps, VisualOrderSt
const unitAmount = ZeroEx.toUnitAmount(assetToken.amount, token.decimals);
return (
<div style={{ fontSize: 13 }}>
- {unitAmount.toNumber().toFixed(PRECISION)} {token.symbol}
+ {unitAmount.toNumber().toFixed(configs.AMOUNT_DISPLAY_PRECSION)} {token.symbol}
</div>
);
}