Skip to content
This repository was archived by the owner on Sep 8, 2025. It is now read-only.

Commit cb74258

Browse files
feat: consume is_expired (#1333)
1 parent 2b3a93d commit cb74258

File tree

2 files changed

+16
-0
lines changed

2 files changed

+16
-0
lines changed

src/ui/common/api/getNetworkInfo.ts

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,13 @@ export interface BtcCheckpointParams {
1515
btc_confirmation_depth: number;
1616
}
1717

18+
interface AllowList {
19+
is_expired: boolean;
20+
}
21+
1822
interface StakingStatus {
1923
is_staking_open: boolean;
24+
allow_list?: AllowList;
2025
}
2126

2227
interface NetworkInfoAPI {
@@ -147,6 +152,11 @@ export const getNetworkInfo = async (): Promise<NetworkInfo> => {
147152
return {
148153
stakingStatus: {
149154
isStakingOpen: staking_status.is_staking_open,
155+
allowList: staking_status.allow_list
156+
? {
157+
isExpired: staking_status.allow_list.is_expired,
158+
}
159+
: undefined,
150160
},
151161
params: {
152162
bbnStakingParams: {

src/ui/common/types/networkInfo.ts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,10 @@ export interface NetworkUpgradeConfig {
99
pop?: PopUpgradeConfig[];
1010
}
1111

12+
export interface AllowList {
13+
isExpired: boolean;
14+
}
15+
1216
export interface BbnStakingParamsVersion extends StakingParams {
1317
version: number;
1418
minCommissionRate: string;
@@ -37,8 +41,10 @@ export interface BtcEpochCheckParams {
3741
latestParam: BtcEpochCheckParamsVersion;
3842
versions: BtcEpochCheckParamsVersion[];
3943
}
44+
4045
export interface StakingStatus {
4146
isStakingOpen: boolean;
47+
allowList?: AllowList;
4248
}
4349

4450
export interface Params {

0 commit comments

Comments
 (0)