Skip to content

Commit

Permalink
docs: update download links
Browse files Browse the repository at this point in the history
  • Loading branch information
idootop committed Nov 23, 2024
1 parent 9da042b commit 551855e
Show file tree
Hide file tree
Showing 6 changed files with 22 additions and 12 deletions.
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

Instant AI Face Swap, Hairstyles & Outfits — One click to a brand new you!

[![GitHub release](https://img.shields.io/github/v/release/idootop/MagicMirror.svg)](https://github.com/idootop/MagicMirror/releases) [![Release MagicMirror](https://github.com/idootop/MagicMirror/actions/workflows/build-app.yaml/badge.svg)](https://github.com/idootop/MagicMirror/actions/workflows/build-app.yaml) [![Discord](https://img.shields.io/discord/xxx?logo=discord&logoColor=white)](https://discord.gg/xxx)
[![GitHub release](https://img.shields.io/github/v/release/idootop/MagicMirror.svg)](https://github.com/idootop/MagicMirror/releases) [![Release MagicMirror](https://github.com/idootop/MagicMirror/actions/workflows/build-app.yaml/badge.svg)](https://github.com/idootop/MagicMirror/actions/workflows/build-app.yaml) [![Discord](https://img.shields.io/discord/1309845147433042002?logo=discord&logoColor=white)](https://discord.gg/87RuMC5smy)

![](src/assets/images/magic-mirror.svg)

Expand All @@ -21,9 +21,9 @@ Instant AI Face Swap, Hairstyles & Outfits — One click to a brand new you!
MagicMirror currently supports macOS and Windows:

1. [Download](https://github.com/idootop/MagicMirror/releases/tag/app-v1.0.0)
2. [Usage Guide](#)
2. [Usage Guide](https://thread-sphynx-f26.notion.site/MagicMirror-User-Guide-147aea89ebf680c189cdd76f5668261a)

If you have any questions or need assistance, please [submit an issue]((https://github.com/idootop/MagicMirror/issues)) or join our [Discord server]().
If you have any questions or need assistance, please [submit an issue](https://github.com/idootop/MagicMirror/issues) or join our [Discord server](https://discord.gg/87RuMC5smy).

## Motivation

Expand Down
2 changes: 1 addition & 1 deletion README.zh-CN.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
MagicMirror 目前支持 macOS 和 Windows 系统:

1. [下载安装包](https://github.com/idootop/MagicMirror/releases/tag/app-v1.0.0)
2. [使用教程](#)
2. [使用教程](https://docs.qq.com/doc/p/401be525749f8ccc22d5dc68a9cd9063641b49ad)

如果你还有其他问题,请提交 [Issue](https://github.com/idootop/MagicMirror/issues) 或加入 [QQ 交流群](https://pd.qq.com/s/btxvzr9de)

Expand Down
2 changes: 1 addition & 1 deletion src/assets/locales/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,6 @@
"Switch": "Switch",
"About": "About",
"downloadURL": "https://github.com/idootop/MagicMirror/releases/download/server-v1.0.0/server_{{type}}_{{arch}}.zip",
"downloadTutorial": "https://github.com/idootop/MagicMirror",
"downloadTutorial": "https://thread-sphynx-f26.notion.site/MagicMirror-User-Guide-147aea89ebf680c189cdd76f5668261a",
"aboutLink": "https://github.com/idootop/MagicMirror"
}
2 changes: 1 addition & 1 deletion src/assets/locales/zh.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,6 @@
"Switch": "翻转镜像",
"About": "关于",
"downloadURL": "https://github.com/idootop/MagicMirror/releases/download/server-v1.0.0/server_{{type}}_{{arch}}.zip",
"downloadTutorial": "https://github.com/idootop/MagicMirror",
"downloadTutorial": "https://docs.qq.com/doc/p/401be525749f8ccc22d5dc68a9cd9063641b49ad",
"aboutLink": "https://github.com/idootop/MagicMirror"
}
4 changes: 4 additions & 0 deletions src/hooks/useDownload.ts
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,10 @@ export function useDownload() {
}, []);

const download = useCallback(async () => {
const isDownloaded = await Server.isDownloaded();
if (isDownloaded) {
return true;
}
try {
const states = kDownloadStates.getState();
if (["downloading", "unzipping"].includes(states.status)) {
Expand Down
18 changes: 12 additions & 6 deletions src/pages/Launch.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -42,17 +42,23 @@ export function LaunchPage() {
}
}, [downloadStatus]);

const launching = ["launching", "running"].includes(launchingStatus) ? (
<>
<p>{t("Starting... First load may take longer, please wait.")}</p>
</>
) : null;
const launching =
["idle", "success"].includes(downloadStatus) ||
["launching", "running"].includes(launchingStatus) ? (
<>
<p>{t("Starting... First load may take longer, please wait.")}</p>
</>
) : null;

const downloading = ["downloading", "unzipping", "failed"].includes(
downloadStatus
) ? (
<>
<p>{t("Downloading resources, please wait", { progress })}</p>
<p>
{t("Downloading resources, please wait", {
progress: progress.toFixed(2),
})}
</p>
<ProgressBar progress={progress} />
<p className="c-[rgba(255,255,255,0.6)] text-12px">
{t(
Expand Down

0 comments on commit 551855e

Please sign in to comment.