From 3d5a2ffd66003aae7adab998d2e7c59efbe8986f Mon Sep 17 00:00:00 2001 From: gnomadic Date: Wed, 7 Feb 2024 16:33:50 -0500 Subject: [PATCH] fix(creator): standardizing Actiontypes and making all plugin actions optional (#74) * standardizing action types * adding changeset: * formatting * formatting * chore: format --------- Co-authored-by: gnomadic --- .changeset/pretty-lobsters-report.md | 5 +++++ src/actions/types.ts | 8 ++++---- 2 files changed, 9 insertions(+), 4 deletions(-) create mode 100644 .changeset/pretty-lobsters-report.md diff --git a/.changeset/pretty-lobsters-report.md b/.changeset/pretty-lobsters-report.md new file mode 100644 index 0000000..b1fcfbd --- /dev/null +++ b/.changeset/pretty-lobsters-report.md @@ -0,0 +1,5 @@ +--- +"@rabbitholegg/questdk": minor +--- + +Standardizing ActionParams and no longer requiring some Actions in plugins diff --git a/src/actions/types.ts b/src/actions/types.ts index 4cdbf68..060d258 100644 --- a/src/actions/types.ts +++ b/src/actions/types.ts @@ -93,13 +93,13 @@ export interface IActionPlugin { chainId: number, task?: ActionType, ) => Promise - bridge: ( + bridge?: ( params: BridgeActionParams, ) => Promise | Promise - swap: ( + swap?: ( params: SwapActionParams, ) => Promise | Promise - mint: ( + mint?: ( params: MintActionParams, ) => Promise | Promise stake?: ( @@ -109,7 +109,7 @@ export interface IActionPlugin { params: DelegateActionParams, ) => Promise | Promise burn?: ( - params: DelegateActionParams, + params: BurnActionParams, ) => Promise | Promise quest?: ( params: QuestActionParams,