2023-01-19 11:16:21 +00:00
|
|
|
import { ViewingAsBanner } from '@vegaprotocol/ui-toolkit';
|
2024-03-01 14:25:56 +00:00
|
|
|
import { useVegaWallet } from '@vegaprotocol/wallet-react';
|
2023-01-19 11:16:21 +00:00
|
|
|
|
|
|
|
export const ViewingBanner = () => {
|
|
|
|
const { isReadOnly, pubKey, disconnect } = useVegaWallet();
|
|
|
|
return isReadOnly ? (
|
|
|
|
<ViewingAsBanner pubKey={pubKey} disconnect={disconnect} />
|
2023-05-04 07:51:24 +00:00
|
|
|
) : null;
|
2023-01-19 11:16:21 +00:00
|
|
|
};
|