From 5f601cc6ea9bd885d1f07663652a13dd36ce3f97 Mon Sep 17 00:00:00 2001 From: Oleg Chendighelean Date: Wed, 12 Jun 2024 13:19:28 +0300 Subject: [PATCH] Add advanced settings to multisig sign page --- src/components/AdvancedSettingsAccordion.tsx | 6 +++++- src/components/SendFlow/Multisig/SignPage.tsx | 12 +++++++++--- 2 files changed, 14 insertions(+), 4 deletions(-) diff --git a/src/components/AdvancedSettingsAccordion.tsx b/src/components/AdvancedSettingsAccordion.tsx index 8a9a00e8f2..1afd0077fa 100644 --- a/src/components/AdvancedSettingsAccordion.tsx +++ b/src/components/AdvancedSettingsAccordion.tsx @@ -19,7 +19,11 @@ import colors from "../style/colors"; import { mutezToTez, tezToMutez } from "../utils/format"; import { Estimation, TEZ_DECIMALS } from "../utils/tezos"; -export const AdvancedSettingsAccordion = ({ index = 0 }) => { +type AdvancedSettingsAccordionProps = { + index?: number; +}; + +export const AdvancedSettingsAccordion = ({ index = 0 }: AdvancedSettingsAccordionProps) => { const { register, getValues, diff --git a/src/components/SendFlow/Multisig/SignPage.tsx b/src/components/SendFlow/Multisig/SignPage.tsx index 4b9cb6d1d2..9285dce95f 100644 --- a/src/components/SendFlow/Multisig/SignPage.tsx +++ b/src/components/SendFlow/Multisig/SignPage.tsx @@ -9,6 +9,7 @@ import { EstimatedAccountOperations } from "../../../types/AccountOperations"; import { ApproveOrExecute } from "../../../types/Operation"; import { useAsyncActionHandler } from "../../../utils/hooks/useAsyncActionHandler"; import { executeOperations } from "../../../utils/tezos"; +import { AdvancedSettingsAccordion } from "../../AdvancedSettingsAccordion"; import { DynamicModalContext } from "../../DynamicModal"; import { BatchModalBody } from "../BatchModalBody"; import { SignButton } from "../SignButton"; @@ -28,7 +29,8 @@ export const SignPage: React.FC<{ defaultValues: { executeParams: operation.estimates }, }); - // TODO: add advanced execute params component + const updatedOperation = { ...operation, estimates: form.watch("executeParams") }; + const approveOrExecute = (tezosToolkit: TezosToolkit) => handleAsyncAction( async () => { @@ -48,8 +50,12 @@ export const SignPage: React.FC<{
- - + +