import React from 'react';
import { Link } from 'react-router-dom';
import { useAuth } from '@/contexts/AuthContext';
import { useForum } from '@/contexts/ForumContext';
import { Button } from '@/components/ui/button';
import { Badge } from '@/components/ui/badge';
import { ShieldCheck, LogOut, Terminal, Wifi, WifiOff, Eye, MessageSquare, RefreshCw } from 'lucide-react';
import { Tooltip, TooltipContent, TooltipProvider, TooltipTrigger } from '@/components/ui/tooltip';
const Header = () => {
const { currentUser, isAuthenticated, verificationStatus, connectWallet, disconnectWallet, verifyOrdinal } = useAuth();
const { isNetworkConnected, isRefreshing } = useForum();
const handleConnect = async () => {
await connectWallet();
};
const handleDisconnect = () => {
disconnectWallet();
};
const handleVerify = async () => {
await verifyOrdinal();
};
const renderAccessBadge = () => {
if (verificationStatus === 'unverified') {
return (
);
}
if (verificationStatus === 'verifying') {
return (
Wallet Verified - No Ordinals Found
Your wallet has been verified but does not contain any Ordinal Operators.
You can browse content but cannot post, comment, or vote.
Verify again
Ordinal Operators Verified!
You have full forum access with permission to post, comment, and vote.
Verify again
{isNetworkConnected ? "Connected to Waku network" : "Not connected to Waku network. Some features may be unavailable."}
{isRefreshing &&Refreshing data...
}