Skip to content

Commit

Permalink
Merge pull request #36 from syscoin/admin-panel
Browse files Browse the repository at this point in the history
Admin panel
  • Loading branch information
osiastedian authored Dec 11, 2023
2 parents 4aa764a + c0cd1bc commit 0e9e4cd
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 4 deletions.
9 changes: 8 additions & 1 deletion components/Bridge/WalletSwitchV2/UTXOConnect.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,13 @@ const UTXOConnect: React.FC<UTXOConnectProps> = ({
}
const emptySysxBalance =
sysxBalance.data === undefined || sysxBalance.data === 0;
if ((sysxBalance.isError || emptySysxBalance) && setSelectedAsset) {

const sysxIsInvalid = sysxBalance.isError || emptySysxBalance;

if (
(sysxIsInvalid || transfer.type === "nevm-to-sys") &&
setSelectedAsset
) {
setSelectedAsset("sys");
}
}, [
Expand All @@ -76,6 +82,7 @@ const UTXOConnect: React.FC<UTXOConnectProps> = ({
sysxBalance.data,
sysxBalance.isFetched,
transfer.utxoAddress,
transfer.type,
isBitcoinBased,
]);

Expand Down
10 changes: 7 additions & 3 deletions pages/bridge/v3/[id].tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,11 @@ import NEVMProvider from "@contexts/ConnectedWallet/NEVMProvider";
import ConnectedWalletProvider from "@contexts/ConnectedWallet/Provider";
import MetamaskProvider from "@contexts/Metamask/Provider";
import { PaliWalletV2Provider } from "@contexts/PaliWallet/V2Provider";
import { COMMON_STATUS, ITransfer, TransferType } from "@contexts/Transfer/types";
import {
COMMON_STATUS,
ITransfer,
TransferType,
} from "@contexts/Transfer/types";
import {
Box,
Button,
Expand Down Expand Up @@ -49,7 +53,7 @@ const createTransfer = (type: TransferType): ITransfer => ({
logs: [],
createdAt: Date.now(),
version: "v2",
agreedToTerms: false
agreedToTerms: false,
});

const BridgeV3Page: NextPage = () => {
Expand All @@ -75,7 +79,7 @@ const BridgeV3Page: NextPage = () => {
<NEVMProvider>
<ConnectedWalletProvider>
<TransferContextProvider transfer={initialTransfer}>
<Container sx={{ mt: 10 }}>
<Container sx={{ mt: 10, mb: 15 }}>
<BlocktimeDisclaimer />
<Typography variant="h5" fontWeight="bold">
Bridge Your SYS
Expand Down

1 comment on commit 0e9e4cd

@vercel
Copy link

@vercel vercel bot commented on 0e9e4cd Dec 11, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

syscoin-bridge – ./

syscoin-bridge-syslabs.vercel.app
syscoin-bridge-git-main-syslabs.vercel.app
syscoin-bridge-fawn.vercel.app

Please sign in to comment.