* Add Deposit cap for AssetSelector * Add DepositCap component for Trade * DepositCap to Vault and Fund * DepositCap to Vault and Fund * Small bugixes * formatting fixes * formatting fixes * formatting fixes * formatting fixes * run format
6 lines
186 B
TypeScript
6 lines
186 B
TypeScript
import { DEPOSIT_CAP_BUFFER } from 'utils/constants'
|
|
|
|
export function getCapLeftWithBuffer(cap: DepositCap) {
|
|
return cap.max.minus(cap.used).times(DEPOSIT_CAP_BUFFER).integerValue()
|
|
}
|