diff --git a/.changeset/funny-rockets-glow.md b/.changeset/funny-rockets-glow.md new file mode 100644 index 000000000..e468d6cdd --- /dev/null +++ b/.changeset/funny-rockets-glow.md @@ -0,0 +1,5 @@ +--- +"@ledgerhq/device-signer-kit-ethereum": patch +--- + +Add user interaction for sign typed object device action that was removed before diff --git a/packages/signer/signer-eth/src/internal/app-binder/device-action/SignTypedData/SignTypedDataDeviceAction.test.ts b/packages/signer/signer-eth/src/internal/app-binder/device-action/SignTypedData/SignTypedDataDeviceAction.test.ts index eab8fbc72..a0611a446 100644 --- a/packages/signer/signer-eth/src/internal/app-binder/device-action/SignTypedData/SignTypedDataDeviceAction.test.ts +++ b/packages/signer/signer-eth/src/internal/app-binder/device-action/SignTypedData/SignTypedDataDeviceAction.test.ts @@ -167,7 +167,7 @@ describe("SignTypedDataDeviceAction", () => { }, { intermediateValue: { - requiredUserInteraction: UserInteractionRequired.None, + requiredUserInteraction: UserInteractionRequired.SignTypedData, }, status: DeviceActionStatus.Pending, }, @@ -277,7 +277,7 @@ describe("SignTypedDataDeviceAction", () => { }, { intermediateValue: { - requiredUserInteraction: UserInteractionRequired.None, + requiredUserInteraction: UserInteractionRequired.SignTypedData, }, status: DeviceActionStatus.Pending, }, @@ -437,7 +437,7 @@ describe("SignTypedDataDeviceAction", () => { }, { intermediateValue: { - requiredUserInteraction: UserInteractionRequired.None, + requiredUserInteraction: UserInteractionRequired.SignTypedData, }, status: DeviceActionStatus.Pending, }, @@ -504,7 +504,7 @@ describe("SignTypedDataDeviceAction", () => { }, { intermediateValue: { - requiredUserInteraction: UserInteractionRequired.None, + requiredUserInteraction: UserInteractionRequired.SignTypedData, }, status: DeviceActionStatus.Pending, }, diff --git a/packages/signer/signer-eth/src/internal/app-binder/device-action/SignTypedData/SignTypedDataDeviceAction.ts b/packages/signer/signer-eth/src/internal/app-binder/device-action/SignTypedData/SignTypedDataDeviceAction.ts index 539eae3e9..592d33e61 100644 --- a/packages/signer/signer-eth/src/internal/app-binder/device-action/SignTypedData/SignTypedDataDeviceAction.ts +++ b/packages/signer/signer-eth/src/internal/app-binder/device-action/SignTypedData/SignTypedDataDeviceAction.ts @@ -195,6 +195,16 @@ export class SignTypedDataDeviceAction extends XStateDeviceAction< }, }, ProvideContext: { + entry: assign({ + intermediateValue: { + requiredUserInteraction: UserInteractionRequired.SignTypedData, + }, + }), + exit: assign({ + intermediateValue: { + requiredUserInteraction: UserInteractionRequired.None, + }, + }), invoke: { id: "provideContext", src: "provideContext",