Skip to content

Commit

Permalink
fix: stake statuses (#200)
Browse files Browse the repository at this point in the history
Instead of having multiple statuses we are now opting for one stake
status. Aligning with the changes on cgw in this PR:
safe-global/safe-client-gateway#1957
  • Loading branch information
compojoom authored Sep 26, 2024
1 parent 3e3ceef commit 70a9ec2
Showing 1 changed file with 9 additions and 15 deletions.
24 changes: 9 additions & 15 deletions src/types/decoded-data.ts
Original file line number Diff line number Diff line change
Expand Up @@ -62,20 +62,14 @@ export type TwapOrderConfirmationView = {
export type AnySwapOrderConfirmationView = SwapOrderConfirmationView | TwapOrderConfirmationView

export enum NativeStakingStatus {
AWAITING_ENTRY = 'AWAITING_ENTRY',
REQUESTED_EXIT = 'REQUESTED_EXIT',
SIGNATURE_NEEDED = 'SIGNATURE_NEEDED',
AWAITING_EXECUTION = 'AWAITING_EXECUTION',
VALIDATION_STARTED = 'VALIDATION_STARTED',
WITHDRAWN = 'WITHDRAWN',
UNKNOWN = 'UNKNOWN',
}

export enum NativeStakingExitStatus {
AWAITING_EXECUTION = 'AWAITING_EXECUTION',
READY_TO_WITHDRAW = 'READY_TO_WITHDRAW',
REQUEST_PENDING = 'REQUEST_PENDING',
SIGNATURE_NEEDED = 'SIGNATURE_NEEDED',
NOT_STAKED = 'NOT_STAKED',
ACTIVATING = 'ACTIVATING',
DEPOSIT_IN_PROGRESS = 'DEPOSIT_IN_PROGRESS',
ACTIVE = 'ACTIVE',
EXIT_REQUESTED = 'EXIT_REQUESTED',
EXITING = 'EXITING',
EXITED = 'EXITED',
SLASHED = 'SLASHED',
}

/* Staking */
Expand All @@ -99,7 +93,7 @@ export type NativeStakingDepositConfirmationView = {

export type NativeStakingValidatorsExitConfirmationView = {
type: ConfirmationViewTypes.KILN_NATIVE_STAKING_VALIDATORS_EXIT
status: NativeStakingExitStatus
status: NativeStakingStatus
estimatedExitTime: number
estimatedWithdrawalTime: number
value: string
Expand Down

0 comments on commit 70a9ec2

Please sign in to comment.