mirror of
https://github.com/dream-pep/koring-launcher.git
synced 2026-09-12 05:45:18 +08:00
Route Minecraft/Fabric/Forge downloads through BMCLAPI mirror and update installer logic. Added mirror rewrite utility (rewriteToMirror), mirror-aware downloadFile, and mirrorFetch; switched version manifest and metadata endpoints to bmclapi2.bangbang93.com and wired maven/assets hosts into xmcl/installer calls. Cleaned up compiled electron JS files and consolidated runtime files under electron-dist; updated electron-builder.yml (compression, asar, NSIS settings, license/installer assets and languages). Minor env/path changes (VITE_APP_ICON paths), added .npmrc (electron_mirror), new Koring.yml, pnpm-workspace and public installer assets. Also added/updated multiple frontend pages, store components, and TypeScript handlers to integrate the changes.
33 lines
1.2 KiB
TypeScript
33 lines
1.2 KiB
TypeScript
import { useRouteStore } from "@/stores/routeStore";
|
|
import { OobeLayout } from "./layout";
|
|
import { NextButton } from "./next-button";
|
|
import { VersionCard } from "@/components/VersionCard";
|
|
import { BUILD_MODE } from "@/lib/mode";
|
|
|
|
export function OobeVersion() {
|
|
const navigate = useRouteStore((s) => s.navigate);
|
|
|
|
const isTestBuild = BUILD_MODE === "dev" || BUILD_MODE === "beta";
|
|
|
|
// 临时跳过 Koring 账户登录环节:正式版也直接进入用户协议
|
|
const nextRoute = isTestBuild ? "oobe/beta-test" : "oobe/agreement";
|
|
|
|
return (
|
|
<OobeLayout>
|
|
<div className="w-full max-w-lg flex flex-col items-center gap-4 px-6">
|
|
{/* 版本卡片(OOBE 模式:无更新逻辑,按钮仅展示样式) */}
|
|
<VersionCard oobe className="w-full" />
|
|
|
|
{/* 测试版警告 */}
|
|
{isTestBuild && (
|
|
<p className="text-xs text-muted-foreground text-center max-w-sm leading-relaxed">
|
|
您正在使用测试版本,它并不稳定,不建议用于正式游戏体验,具体内容请以发行版本为准。
|
|
</p>
|
|
)}
|
|
</div>
|
|
|
|
<NextButton onClick={() => navigate(nextRoute)} />
|
|
</OobeLayout>
|
|
);
|
|
}
|