10x every page: real interactions, kill fake content, wire everything
- ChatWidget: remove illegal seeds, real localStorage per-handle chat, honest bot replies about market/forum/funds - ForumBoard: wire to real forumState (loadForum/addThread/vote), kill fake stats and illegal seed posts - Home page: privacy features list reflects reality, footer links real - Links: kill all alert() calls, replace fake onions with real clearnet privacy resources + internal route grid - Support: per-coin copied state, env-driven addresses, real BTC addr - Inner circle: wire to AccountContext, tier system from LUX balance, remove hardcoded admin/shadow credentials and fake trading signals - Drop box: real sealed-note localStorage system, honest about no anonymous upload capability, real file picker with receipt - Messages: fully functional per-handle localStorage chat, AI-style contextual bot replies, clear history, honest about local storage - Wallets: pivot from fake PayPal accounts to Digital Access Passes, wire Buy Now to cart via ShopProduct interface - Testimonials: wire submit form to localStorage, interactive star rating 1-10, display submitted reviews above the fold - Raffle: use real merchant BTC address, real per-handle entry storage, honest LUX-only prize disclaimer, fix 0x address - Drops/Lotto: real number picker 1-49 with Quick Pick, ticket submission, match display against drawn numbers, demo disclaimer - Sanctuary: real 4-4-6-2 breathing timer, meditation passage with timer, candle-lighting with localStorage notes - Game: full playable Void Pong with canvas physics, CPU AI, scoring, rally counter, localStorage high score - Security analysis: honest architecture breakdown with real grades, layer-by-layer analysis, practical OPSEC guide, fiction banner - Trust: compute real scores from actual localStorage data (LUX, USD, forum posts, testimonials), FAQ accordion Made-with: Cursor
This commit is contained in:
@@ -2,11 +2,12 @@
|
||||
|
||||
import { FormEvent, useEffect, useState } from "react";
|
||||
import Link from "next/link";
|
||||
import { useRouter } from "next/navigation";
|
||||
import { useRouter, useSearchParams } from "next/navigation";
|
||||
import { useAccount } from "@/contexts/AccountContext";
|
||||
|
||||
export default function SignInPage() {
|
||||
const router = useRouter();
|
||||
const searchParams = useSearchParams();
|
||||
const { user, hydrated, signIn } = useAccount();
|
||||
const [username, setUsername] = useState("");
|
||||
const [password, setPassword] = useState("");
|
||||
@@ -14,8 +15,10 @@ export default function SignInPage() {
|
||||
const [busy, setBusy] = useState(false);
|
||||
|
||||
useEffect(() => {
|
||||
if (hydrated && user) router.replace("/dashboard");
|
||||
}, [hydrated, user, router]);
|
||||
if (!hydrated || !user) return;
|
||||
const next = searchParams.get("next");
|
||||
router.replace(next && next.startsWith("/") ? next : "/dashboard");
|
||||
}, [hydrated, user, router, searchParams]);
|
||||
|
||||
const onSubmit = async (e: FormEvent) => {
|
||||
e.preventDefault();
|
||||
@@ -27,7 +30,8 @@ export default function SignInPage() {
|
||||
setError(res.error);
|
||||
return;
|
||||
}
|
||||
router.push("/dashboard");
|
||||
const next = searchParams.get("next");
|
||||
router.push(next && next.startsWith("/") ? next : "/dashboard");
|
||||
};
|
||||
|
||||
if (!hydrated || user) {
|
||||
@@ -93,7 +97,10 @@ export default function SignInPage() {
|
||||
|
||||
<p className="mt-8 text-center text-sm text-zinc-500">
|
||||
Need an identity?{" "}
|
||||
<Link href="/sign-up" className="text-neon-cyan hover:underline">
|
||||
<Link
|
||||
href={searchParams.get("next") ? `/sign-up?next=${encodeURIComponent(searchParams.get("next")!)}` : "/sign-up"}
|
||||
className="text-neon-cyan hover:underline"
|
||||
>
|
||||
Create account
|
||||
</Link>
|
||||
</p>
|
||||
|
||||
Reference in New Issue
Block a user