update with correct abacus version
This commit is contained in:
parent
8bca03b030
commit
906e5548d3
@ -39,7 +39,7 @@
|
||||
"@cosmjs/proto-signing": "^0.32.1",
|
||||
"@cosmjs/stargate": "^0.32.1",
|
||||
"@cosmjs/tendermint-rpc": "^0.32.1",
|
||||
"@dydxprotocol/v4-abacus": "^1.2.8",
|
||||
"@dydxprotocol/v4-abacus": "^1.3.2",
|
||||
"@dydxprotocol/v4-client-js": "^1.0.17",
|
||||
"@dydxprotocol/v4-localization": "^1.1.15",
|
||||
"@ethersproject/providers": "^5.7.2",
|
||||
|
||||
8
pnpm-lock.yaml
generated
8
pnpm-lock.yaml
generated
@ -27,8 +27,8 @@ dependencies:
|
||||
specifier: ^0.32.1
|
||||
version: 0.32.2
|
||||
'@dydxprotocol/v4-abacus':
|
||||
specifier: ^1.2.8
|
||||
version: 1.2.8
|
||||
specifier: ^1.3.2
|
||||
version: 1.3.2
|
||||
'@dydxprotocol/v4-client-js':
|
||||
specifier: ^1.0.17
|
||||
version: 1.0.17
|
||||
@ -1086,8 +1086,8 @@ packages:
|
||||
resolution: {integrity: sha512-RpfLEtTlyIxeNPGKcokS+p3BZII/Q3bYxryFRglh5H3A3T8q9fsLYm72VYAMEOOIBLEa8o93kFLiBDUWKrwXZA==}
|
||||
dev: true
|
||||
|
||||
/@dydxprotocol/v4-abacus@1.2.8:
|
||||
resolution: {integrity: sha512-rW+9r3cymCFn054Spbw91CXprMpnP6f5C/lSNQ1ptoer5r6FlTUa1tu1+j3YaNSkazqigifK+Eu0IwDmvAS28w==}
|
||||
/@dydxprotocol/v4-abacus@1.3.2:
|
||||
resolution: {integrity: sha512-zo0IHjGMlJRKOYDgNqNFQ9GtBJKJP4+Y9YY7V0X3Wt61ppKAYzodaYQhc9V/RYchcZTtS/xkicLug444YrvehQ==}
|
||||
dev: false
|
||||
|
||||
/@dydxprotocol/v4-client-js@1.0.17:
|
||||
|
||||
@ -96,6 +96,8 @@ export const useTradeFormData = () => {
|
||||
needsGoodUntil,
|
||||
needsPostOnly,
|
||||
needsReduceOnly,
|
||||
postOnlyTooltip,
|
||||
reduceOnlyTooltip,
|
||||
timeInForceOptions,
|
||||
} = tradeOptions || {};
|
||||
|
||||
@ -111,6 +113,8 @@ export const useTradeFormData = () => {
|
||||
needsGoodUntil,
|
||||
needsPostOnly,
|
||||
needsReduceOnly,
|
||||
postOnlyTooltip,
|
||||
reduceOnlyTooltip,
|
||||
timeInForceOptions,
|
||||
|
||||
tradeErrors,
|
||||
|
||||
@ -10,7 +10,6 @@ import {
|
||||
type HumanReadablePlaceOrderPayload,
|
||||
type Nullable,
|
||||
TradeInputErrorAction,
|
||||
TradeInputField,
|
||||
ValidationError,
|
||||
} from '@/constants/abacus';
|
||||
|
||||
@ -96,6 +95,8 @@ export const TradeForm = ({
|
||||
needsGoodUntil,
|
||||
needsPostOnly,
|
||||
needsReduceOnly,
|
||||
postOnlyTooltip,
|
||||
reduceOnlyTooltip,
|
||||
timeInForceOptions,
|
||||
tradeErrors,
|
||||
} = useTradeFormData();
|
||||
@ -108,7 +109,7 @@ export const TradeForm = ({
|
||||
const { limitPriceInput, triggerPriceInput, trailingPercentInput } = tradeFormInputValues;
|
||||
|
||||
const needsAdvancedOptions =
|
||||
needsGoodUntil || timeInForceOptions || executionOptions || needsPostOnly || needsReduceOnly;
|
||||
needsGoodUntil || timeInForceOptions || executionOptions || (needsPostOnly || postOnlyTooltip) || (needsReduceOnly || reduceOnlyTooltip);
|
||||
|
||||
const tradeFormInputs: TradeBoxInputConfig[] = [];
|
||||
|
||||
|
||||
@ -36,7 +36,10 @@ export const AdvancedTradeOptions = () => {
|
||||
|
||||
const { duration, unit } = goodTil || {};
|
||||
|
||||
const needsExecution = executionOptions || needsPostOnly || needsReduceOnly;
|
||||
const showPostOnly = (needsPostOnly || postOnlyTooltip);
|
||||
const showReduceOnly = (needsReduceOnly || reduceOnlyTooltip);
|
||||
|
||||
const needsExecution = executionOptions || showPostOnly || showReduceOnly;
|
||||
const hasTimeInForce = timeInForceOptions?.toArray()?.length;
|
||||
|
||||
return (
|
||||
@ -129,7 +132,7 @@ export const AdvancedTradeOptions = () => {
|
||||
))}
|
||||
</Styled.SelectMenu>
|
||||
)}
|
||||
{(needsReduceOnly || reduceOnlyTooltip) && <Checkbox
|
||||
{showReduceOnly && <Checkbox
|
||||
checked={(reduceOnly && !reduceOnlyTooltip) || false}
|
||||
disabled={!!reduceOnlyTooltip}
|
||||
onCheckedChange={(checked) =>
|
||||
@ -146,7 +149,7 @@ export const AdvancedTradeOptions = () => {
|
||||
}
|
||||
/>
|
||||
}
|
||||
{(needsPostOnly || postOnlyTooltip) && (
|
||||
{showPostOnly && (
|
||||
<Checkbox
|
||||
checked={(postOnly && !postOnlyTooltip) || false}
|
||||
disabled={!!postOnlyTooltip}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user