登录页与激活页互加入口链接
孩子设备打开网站落在登录页,原先没有去激活页的路径,补上双向链接。 Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 4.8
parent
9dd0c66237
commit
b08f6649be
@@ -1,6 +1,7 @@
|
||||
"use client";
|
||||
|
||||
import { useActionState } from "react";
|
||||
import Link from "next/link";
|
||||
import { activate } from "./actions";
|
||||
import { Button } from "@/components/ui/button";
|
||||
import { Card, CardContent, CardHeader, CardTitle } from "@/components/ui/card";
|
||||
@@ -42,6 +43,15 @@ export default function JoinPage() {
|
||||
<Button type="submit" className="w-full" size="lg" disabled={pending}>
|
||||
{pending ? "激活中…" : "激活"}
|
||||
</Button>
|
||||
<p className="text-center text-sm text-muted-foreground">
|
||||
我是家长,{" "}
|
||||
<Link
|
||||
href="/login"
|
||||
className="font-medium text-primary underline-offset-4 hover:underline"
|
||||
>
|
||||
去登录
|
||||
</Link>
|
||||
</p>
|
||||
</form>
|
||||
</CardContent>
|
||||
</Card>
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
"use client";
|
||||
|
||||
import { useActionState } from "react";
|
||||
import Link from "next/link";
|
||||
import { login } from "./actions";
|
||||
import { Button } from "@/components/ui/button";
|
||||
import { Card, CardContent, CardHeader, CardTitle } from "@/components/ui/card";
|
||||
@@ -47,6 +48,15 @@ export default function LoginPage() {
|
||||
<Button type="submit" className="w-full" size="lg" disabled={pending}>
|
||||
{pending ? "登录中…" : "登录"}
|
||||
</Button>
|
||||
<p className="text-center text-sm text-muted-foreground">
|
||||
孩子的设备第一次使用?{" "}
|
||||
<Link
|
||||
href="/join"
|
||||
className="font-medium text-primary underline-offset-4 hover:underline"
|
||||
>
|
||||
去输入激活码
|
||||
</Link>
|
||||
</p>
|
||||
</form>
|
||||
</CardContent>
|
||||
</Card>
|
||||
|
||||
Reference in New Issue
Block a user