mirror of
https://github.com/YuzuZensai/VRC-Circle.git
synced 2026-09-13 19:08:52 +00:00
✨ feat: Installation of Unity Hub
This commit is contained in:
@@ -94,7 +94,8 @@ const handlers = {
|
||||
"unity:status": () => guard(() => unity.unityStatus()),
|
||||
"unity:install": (url) =>
|
||||
guard(async () => {
|
||||
if (!url.startsWith("unityhub://")) throw new Error("Invalid Unity Hub link");
|
||||
if (!url.startsWith("unityhub://") && !url.startsWith("https://unity.com/"))
|
||||
throw new Error("Invalid Unity Hub link");
|
||||
await shell.openExternal(url);
|
||||
}),
|
||||
|
||||
|
||||
@@ -425,7 +425,14 @@ function UnityStatusBody({ status }: { status: UnityStatus }) {
|
||||
{t(verdict.key)}
|
||||
</span>
|
||||
</div>
|
||||
{status.match !== "ok" && status.installUrl ? (
|
||||
{!status.hubInstalled ? (
|
||||
<div className="mt-1">
|
||||
<Button onClick={() => void api.unity.install("https://unity.com/download")}>
|
||||
<Download size={14} />
|
||||
{t("settings:unity.getHub")}
|
||||
</Button>
|
||||
</div>
|
||||
) : status.match !== "ok" && status.installUrl ? (
|
||||
<div className="mt-1">
|
||||
<Button onClick={() => void api.unity.install(status.installUrl as string)}>
|
||||
<Download size={14} />
|
||||
|
||||
@@ -68,6 +68,7 @@
|
||||
"installedVersions": "Installed editors",
|
||||
"status": "Status",
|
||||
"install": "Install {{version}} in Unity Hub",
|
||||
"getHub": "Get Unity Hub",
|
||||
"match": {
|
||||
"ok": "Match",
|
||||
"missing": "Version not installed",
|
||||
|
||||
@@ -68,6 +68,7 @@
|
||||
"installedVersions": "インストール済みエディター",
|
||||
"status": "状態",
|
||||
"install": "Unity Hub で {{version}} をインストール",
|
||||
"getHub": "Unity Hub を入手",
|
||||
"match": {
|
||||
"ok": "一致",
|
||||
"missing": "そのバージョンが未インストール",
|
||||
|
||||
@@ -68,6 +68,7 @@
|
||||
"installedVersions": "เอดิเตอร์ที่ติดตั้ง",
|
||||
"status": "สถานะ",
|
||||
"install": "ติดตั้ง {{version}} ใน Unity Hub",
|
||||
"getHub": "ดาวน์โหลด Unity Hub",
|
||||
"match": {
|
||||
"ok": "ตรงกัน",
|
||||
"missing": "ยังไม่ได้ติดตั้งเวอร์ชันนี้",
|
||||
|
||||
Reference in New Issue
Block a user