+
+
+
+
+ Decentralized Cells
+
+
+ Discover communities built on Bitcoin Ordinals
+
+
-
-
+ {/* Only show controls when cells exist */}
+ {hasCells && (
+
+
-
+
-
-
+
+
+ {canCreateCell && (
+
+ )}
+
+ )}
- {sortedCells.length === 0 ? (
-
-
- No cells found. Be the first to create one!
-
-
+ {!hasCells ? (
+
) : (
sortedCells.map(cell =>
)
)}
-
- {canCreateCell && (
-
-
- Ready to start your own community?
-
-
-
- )}
);
};
diff --git a/src/components/Header.tsx b/src/components/Header.tsx
index bed914c..f608d6a 100644
--- a/src/components/Header.tsx
+++ b/src/components/Header.tsx
@@ -7,6 +7,7 @@ import { useForum } from '@/contexts/useForum';
import { localDatabase } from '@/lib/database/LocalDatabase';
import { DelegationFullStatus } from '@/lib/delegation';
import { Button } from '@/components/ui/button';
+import { Badge } from '@/components/ui/badge';
import {
LogOut,
@@ -19,12 +20,18 @@ import {
Grid3X3,
User,
Bookmark,
+ Settings,
+ Menu,
+ X,
+ Clock,
} from 'lucide-react';
import {
- Tooltip,
- TooltipContent,
- TooltipTrigger,
-} from '@/components/ui/tooltip';
+ DropdownMenu,
+ DropdownMenuContent,
+ DropdownMenuItem,
+ DropdownMenuSeparator,
+ DropdownMenuTrigger,
+} from '@/components/ui/dropdown-menu';
import { useToast } from '@/components/ui/use-toast';
import { useAppKitAccount, useDisconnect } from '@reown/appkit/react';
import { WalletWizard } from '@/components/ui/wallet-wizard';
@@ -58,6 +65,7 @@ const Header = () => {
: undefined;
const [walletWizardOpen, setWalletWizardOpen] = useState(false);
+ const [mobileMenuOpen, setMobileMenuOpen] = useState(false);
// ✅ Get display name from enhanced hook
const { displayName } = useUserDisplay(address || '');
@@ -101,6 +109,10 @@ const Header = () => {
setWalletWizardOpen(true);
};
+ const handleOpenWizard = () => {
+ setWalletWizardOpen(true);
+ };
+
const handleDisconnect = async () => {
await disconnect();
await setHasShownWizard(false); // Reset so wizard can show again on next connection
@@ -110,36 +122,6 @@ const Header = () => {
});
};
- const getAccountStatusText = () => {
- if (!isConnected) return 'Connect Wallet';
-
- if (verificationStatus === EVerificationStatus.ENS_ORDINAL_VERIFIED) {
- return delegationInfo?.isValid ? 'Ready to Post' : 'Delegation Expired';
- } else if (verificationStatus === EVerificationStatus.WALLET_CONNECTED) {
- return 'Verified (Read-only)';
- } else {
- return 'Verify Wallet';
- }
- };
-
- const getStatusColor = () => {
- if (!isConnected) return 'text-red-400';
-
- if (
- verificationStatus === EVerificationStatus.ENS_ORDINAL_VERIFIED &&
- delegationInfo?.isValid
- ) {
- return 'text-green-400';
- } else if (verificationStatus === EVerificationStatus.WALLET_CONNECTED) {
- return 'text-yellow-400';
- } else if (
- verificationStatus === EVerificationStatus.ENS_ORDINAL_VERIFIED
- ) {
- return 'text-orange-400';
- } else {
- return 'text-red-400';
- }
- };
const getStatusIcon = () => {
if (!isConnected) return
;
@@ -161,140 +143,278 @@ const Header = () => {
};
return (
-
-
-
- {/* Logo and Navigation */}
-
-
-
- opchan
-
-
-
+
{/* Wallet Wizard */}
{
});
}}
/>
-
+ >
);
};
diff --git a/src/components/PostCard.tsx b/src/components/PostCard.tsx
index 0b20bf0..e290222 100644
--- a/src/components/PostCard.tsx
+++ b/src/components/PostCard.tsx
@@ -99,7 +99,7 @@ const PostCard: React.FC = ({ post, commentCount = 0 }) => {
};
return (
-
+
{/* Voting column */}
diff --git a/src/components/PostDetail.tsx b/src/components/PostDetail.tsx
index a6d78c0..79e3364 100644
--- a/src/components/PostDetail.tsx
+++ b/src/components/PostDetail.tsx
@@ -48,7 +48,7 @@ const PostDetail = () => {
isBookmarked,
loading: bookmarkLoading,
toggleBookmark,
- } = usePostBookmark(post!, post?.cellId);
+ } = usePostBookmark(post, post?.cellId);
// ✅ Move ALL hook calls to the top, before any conditional logic
const postPending = usePending(post?.id);
diff --git a/src/components/PostList.tsx b/src/components/PostList.tsx
index 9971dc3..01ebbe9 100644
--- a/src/components/PostList.tsx
+++ b/src/components/PostList.tsx
@@ -151,8 +151,8 @@ const PostList = () => {
};
return (
-
-
+
+
{
-
+
{
/>
-
{cell.name}
+ {cell.name}
-
{cell.description}
+
{cell.description}
{canPost && (
-