Skip to content

Commit

Permalink
Hotfix approaching tvl cap (#335)
Browse files Browse the repository at this point in the history
  • Loading branch information
jrwbabylonlab authored Jul 10, 2024
2 parents df008dc + ae0b803 commit c7498c4
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 5 deletions.
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "simple-staking",
"version": "0.2.7",
"version": "0.2.8",
"private": true,
"scripts": {
"dev": "next dev",
Expand Down
7 changes: 5 additions & 2 deletions src/app/components/Staking/Staking.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,10 @@ import { Dispatch, SetStateAction, useEffect, useMemo, useState } from "react";
import { Tooltip } from "react-tooltip";
import { useLocalStorage } from "usehooks-ts";

import { OVERFLOW_HEIGHT_WARNING_THRESHOLD } from "@/app/common/constants";
import {
OVERFLOW_HEIGHT_WARNING_THRESHOLD,
OVERFLOW_TVL_WARNING_THRESHOLD,
} from "@/app/common/constants";
import { LoadingView } from "@/app/components/Loading/Loading";
import { useError } from "@/app/context/Error/ErrorContext";
import { useGlobalParams } from "@/app/context/api/GlobalParamsProvider";
Expand Down Expand Up @@ -190,7 +193,7 @@ export const Staking: React.FC<StakingProps> = ({
isHeightCap: false,
overTheCapRange: stakingCapSat <= activeTVLSat,
approchingCapRange:
stakingCapSat * OVERFLOW_HEIGHT_WARNING_THRESHOLD < unconfirmedTVLSat,
stakingCapSat * OVERFLOW_TVL_WARNING_THRESHOLD < unconfirmedTVLSat,
});
}
}, [paramWithCtx, btcHeight, stakingStats]);
Expand Down

0 comments on commit c7498c4

Please sign in to comment.