feat: 增强钱包 API 与玩家会话管理
- 新增钱包 API 函数:getWalletLogs(获取钱包日志)、postWalletTransferIn(充值)及 postWalletTransferOut(提现) - 更新钱包相关类型定义,提升类型安全性 - 改进玩家会话管理:若当前无玩家资料,则自动拉取玩家信息 - 增强入口网关对过期会话的错误处理能力 - 更新 UI 组件,以适配新的结构与功能
This commit is contained in:
@@ -1,5 +1,8 @@
|
||||
import Link from "next/link";
|
||||
import type { ReactNode } from "react";
|
||||
|
||||
import { PlayerSessionBar } from "@/features/player/player-session-bar";
|
||||
|
||||
type PlayerAppShellProps = {
|
||||
children: ReactNode;
|
||||
};
|
||||
@@ -12,8 +15,27 @@ export function PlayerAppShell({ children }: PlayerAppShellProps): ReactNode {
|
||||
return (
|
||||
<div className="flex min-h-full flex-col bg-background text-foreground">
|
||||
<header className="sticky top-0 z-40 shrink-0 border-b border-border bg-background/95 backdrop-blur-sm supports-[backdrop-filter]:bg-background/80">
|
||||
<div className="mx-auto flex h-12 max-w-lg items-center px-4">
|
||||
<span className="text-sm font-semibold tracking-tight">Lottery</span>
|
||||
<div className="mx-auto flex h-12 max-w-lg items-center justify-between gap-2 px-4">
|
||||
<div className="flex min-w-0 flex-1 items-center gap-2">
|
||||
<span className="shrink-0 text-sm font-semibold tracking-tight">
|
||||
Lottery
|
||||
</span>
|
||||
<PlayerSessionBar className="min-w-0 border-l border-border pl-2" />
|
||||
</div>
|
||||
<nav className="flex shrink-0 items-center gap-2.5 text-xs font-medium sm:gap-3">
|
||||
<Link
|
||||
href="/hall"
|
||||
className="text-muted-foreground transition-colors hover:text-foreground"
|
||||
>
|
||||
大厅
|
||||
</Link>
|
||||
<Link
|
||||
href="/wallet"
|
||||
className="text-muted-foreground transition-colors hover:text-foreground"
|
||||
>
|
||||
钱包
|
||||
</Link>
|
||||
</nav>
|
||||
</div>
|
||||
</header>
|
||||
<main className="mx-auto flex w-full max-w-lg flex-1 flex-col gap-4 px-4 py-4">
|
||||
|
||||
Reference in New Issue
Block a user