更新脚本修改,福利应用删除

This commit is contained in:
谢宇宁
2026-10-26 21:14:28 +07:00
parent d2c8c63a36
commit ff95c1bdbd
11 changed files with 247 additions and 69 deletions
-4
View File
@@ -10,7 +10,6 @@ import { AuthUnauthorizedBridge } from "@/components/auth/auth-unauthorized-brid
import { GuestAuthBootstrap } from "@/components/auth/guest-auth-bootstrap";
import { LoginDialogHost } from "@/components/auth/login-dialog";
import { ToastHost } from "@/components/common/toast-host";
import { HomeBaseDebugSlot } from "@/components/debug/home-base-debug-slot";
import { DownloadDialogSlot } from "@/components/download/download-dialog-slot";
import { SiteShell } from "@/components/layout/site-shell";
import { browserCompatScript } from "@/lib/browser/compat-inline";
@@ -93,9 +92,6 @@ export default function RootLayout({ children }: LayoutProps<"/">) {
<Suspense fallback={null}>
<RequestHeadersPrime />
</Suspense>
<Suspense fallback={null}>
<HomeBaseDebugSlot />
</Suspense>
<SiteShell>{children}</SiteShell>
<GuestAuthBootstrap />
<AuthUnauthorizedBridge />
-2
View File
@@ -1,7 +1,6 @@
import type { Metadata } from "next";
import { cache } from "react";
import { HomeDataDebug } from "@/components/home/home-data-debug";
import { HomePage } from "@/components/home/home-page";
import { JsonLd } from "@/components/seo/json-ld";
import { dramaHref } from "@/components/short-drama/data";
@@ -75,7 +74,6 @@ export default async function Home() {
return (
<>
<HomeDataDebug home={merged} base={base} />
<JsonLd
data={buildWebPageJSONLD({
path: "/",
@@ -1,17 +0,0 @@
import { connection } from "next/server";
import { getHomeBaseCached } from "@/lib/api/home";
import { HomeBaseDebug } from "./home-base-debug";
/** 调试插槽:拉取 home/base 并在浏览器控制台打印 */
export async function HomeBaseDebugSlot() {
await connection();
let data: Awaited<ReturnType<typeof getHomeBaseCached>> = {};
try {
data = await getHomeBaseCached();
} catch {
data = {};
}
return <HomeBaseDebug data={data} />;
}
-14
View File
@@ -1,14 +0,0 @@
"use client";
import { useEffect } from "react";
import type { HomeBaseResp } from "@/lib/api/types";
/** 浏览器控制台打印 /api/app/home/base 返回数据(调试用) */
export function HomeBaseDebug({ data }: { data: HomeBaseResp }) {
useEffect(() => {
console.info("[home/base]", data);
}, [data]);
return null;
}
-21
View File
@@ -1,21 +0,0 @@
"use client";
import { useEffect } from "react";
import type { AdvitiseData, ConfigInfo, HomePlayletResponse } from "@/lib/api/types";
/** 调试:把首页接口数据打到浏览器控制台 */
export function HomeDataDebug({
home,
base,
}: {
home?: HomePlayletResponse | null;
base?: { advitise?: AdvitiseData; config?: ConfigInfo };
}) {
useEffect(() => {
console.log("[home] playlet/home", home);
console.log("[home] home/base", base);
}, [home, base]);
return null;
}
-2
View File
@@ -14,8 +14,6 @@ export async function getHomeBaseCached(): Promise<HomeBaseResp> {
timeoutMs: 8_000,
maxAttempts: 2,
});
// 调试:服务端终端打印 home/base
console.info("[home/base]", data);
return data;
} catch {
return {};