From f3d2590a44b1aad28cb8d3d018e9dcb49f654ea5 Mon Sep 17 00:00:00 2001 From: speakeloudest Date: Wed, 24 Sep 2025 20:29:28 -0700 Subject: [PATCH 01/12] =?UTF-8?q?fix:=20=E4=BF=AE=E6=94=B9=E4=B8=8B?= =?UTF-8?q?=E8=BD=BD=E8=B7=AF=E5=BE=84?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../(content)/(user)/dashboard/content.tsx | 33 +++++++++++++------ apps/user/locales/en-US/dashboard.json | 5 +++ apps/user/locales/zh-CN/dashboard.json | 5 +++ 3 files changed, 33 insertions(+), 10 deletions(-) diff --git a/apps/user/app/(main)/(content)/(user)/dashboard/content.tsx b/apps/user/app/(main)/(content)/(user)/dashboard/content.tsx index 03e279c..fde5248 100644 --- a/apps/user/app/(main)/(content)/(user)/dashboard/content.tsx +++ b/apps/user/app/(main)/(content)/(user)/dashboard/content.tsx @@ -119,11 +119,11 @@ export default function Content() { {/* 快捷下载 Card */}
-

快捷下载

-
-
- 选择对应操作系统下载客户端 +

+ {t('quickDownloads')} +

+
{t('selectOS')}
{ return ( - +
@@ -159,7 +172,7 @@ export default function Content() { 'mt-2.5 flex h-[37px] items-center justify-between rounded-full bg-[#EAEAEA] pl-4 text-[#666]' } > - 免费美区Apple ID + {t('freeAppleID')} - 获取 + {t('get')}
@@ -190,7 +203,7 @@ export default function Content() {
- 复制订阅链接或点击二维码按钮扫码 + {t('copySubscribeLink')}
diff --git a/apps/user/locales/en-US/dashboard.json b/apps/user/locales/en-US/dashboard.json index 8a8c783..07d34f7 100644 --- a/apps/user/locales/en-US/dashboard.json +++ b/apps/user/locales/en-US/dashboard.json @@ -12,6 +12,7 @@ "confirmResetSubscription": "Are you sure you want to reset the subscription address?", "copy": "Copy", "copyFailure": "Copy failed, please copy manually", + "copySubscribeLink": "Copy the subscription link or click the QR code button to scan", "copySubscriptionLinkOrScanQrCode": "Copy subscription link or click the QR code button to scan", "copySuccess": "Copy successful", "deducted": "Canceled", @@ -19,6 +20,8 @@ "expirationDays": "Expiration Days", "expired": "Expired", "finished": "Traffic exhausted", + "freeAppleID": "Free US Apple ID", + "get": "Get", "import": "Import", "inEffect": "In Effect", "latestAnnouncement": "Latest Announcement", @@ -40,12 +43,14 @@ "prompt": "Prompt", "purchaseSubscription": "Purchase Subscription", "qrCode": "QR Code", + "quickDownloads": "Quick Downloads", "remaining": "Remaining: ", "resetSubscription": "Reset Subscription Address", "resetSuccess": "Reset successful", "rowsPerPage": "Rows per page", "scanCodeToSubscribe": "Scan code to subscribe", "scanToSubscribe": "Scan to Subscribe", + "selectOS": "Select the corresponding operating system to download the client", "siteAnnouncements": "Site Announcements", "subscriptionUrl": "Subscription URL", "totalTraffic": "Total Traffic", diff --git a/apps/user/locales/zh-CN/dashboard.json b/apps/user/locales/zh-CN/dashboard.json index 52cbfc6..34612ef 100644 --- a/apps/user/locales/zh-CN/dashboard.json +++ b/apps/user/locales/zh-CN/dashboard.json @@ -12,6 +12,7 @@ "confirmResetSubscription": "是否确认重置订阅地址?", "copy": "复制", "copyFailure": "复制失败,请手动复制", + "copySubscribeLink": "复制订阅链接或点击二维码按钮扫码", "copySubscriptionLinkOrScanQrCode": "复制订阅链接或点击二维码按钮扫码", "copySuccess": "复制成功", "deducted": "已取消", @@ -19,6 +20,8 @@ "expirationDays": "到期时间/天", "expired": "已过期", "finished": "流量已用尽", + "freeAppleID": "免费美区Apple ID", + "get": "获取", "import": "导入", "inEffect": "生效中", "latestAnnouncement": "最新公告", @@ -40,12 +43,14 @@ "prompt": "提示", "purchaseSubscription": "购买订阅", "qrCode": "二维码", + "quickDownloads": "快捷下载", "remaining": "剩余:", "resetSubscription": "重置订阅地址", "resetSuccess": "重置成功", "rowsPerPage": "每页显示", "scanCodeToSubscribe": "扫描码订阅", "scanToSubscribe": "扫描订阅", + "selectOS": "选择对应操作系统下载客户端", "siteAnnouncements": "网站公告", "subscriptionUrl": "订阅地址", "totalTraffic": "总流量", From 804af6b1fcede1eca1077545dd38db0d5e115178 Mon Sep 17 00:00:00 2001 From: speakeloudest Date: Wed, 24 Sep 2025 22:45:23 -0700 Subject: [PATCH 02/12] =?UTF-8?q?fix:=20=E4=BF=AE=E6=94=B9=E4=B8=8B?= =?UTF-8?q?=E8=BD=BD=E8=B7=AF=E5=BE=84?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- apps/user/app/(main)/(content)/(user)/dashboard/content.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/apps/user/app/(main)/(content)/(user)/dashboard/content.tsx b/apps/user/app/(main)/(content)/(user)/dashboard/content.tsx index fde5248..6eb95fa 100644 --- a/apps/user/app/(main)/(content)/(user)/dashboard/content.tsx +++ b/apps/user/app/(main)/(content)/(user)/dashboard/content.tsx @@ -144,12 +144,12 @@ export default function Content() { { label: 'Win', icon: 'Group 75', - href: 'https://airoport.oss-ap-northeast-1.aliyuncs.com/Hiddify-Windows-Setup-x64.msix', + href: 'https://down.airoport.xin/Hiddify-Windows-Setup-x64.msix', }, { label: 'Android', icon: 'Group 75', - href: 'https://airoport.oss-ap-northeast-1.aliyuncs.com/Hiddify-Android-universal.apk', + href: 'https://down.airoport.xin/Hiddify-Android-universal.apk', }, ].map((v) => { return ( From 8aa9b5694ae2f0cac281e16cb3d4ee0a79285d27 Mon Sep 17 00:00:00 2001 From: speakeloudest Date: Thu, 25 Sep 2025 02:32:17 -0700 Subject: [PATCH 03/12] =?UTF-8?q?fix:=20=E5=A2=9E=E5=8A=A0=E9=BB=98?= =?UTF-8?q?=E8=AE=A4=E7=8A=B6=E6=80=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/SubscribeCard/index.tsx | 63 ++++--- .../(content)/(user)/dashboard/content.tsx | 164 +++++++++--------- .../(user)/document/tutorial-button.tsx | 2 +- .../(main)/(content)/(user)/payment/page.tsx | 2 +- .../airo-ui/src/components/AiroButton.tsx | 3 +- 5 files changed, 130 insertions(+), 104 deletions(-) diff --git a/apps/user/app/(main)/(content)/(user)/dashboard/components/SubscribeCard/index.tsx b/apps/user/app/(main)/(content)/(user)/dashboard/components/SubscribeCard/index.tsx index 285b246..b397f5b 100644 --- a/apps/user/app/(main)/(content)/(user)/dashboard/components/SubscribeCard/index.tsx +++ b/apps/user/app/(main)/(content)/(user)/dashboard/components/SubscribeCard/index.tsx @@ -28,9 +28,11 @@ import { import { Popover, PopoverContent, PopoverTrigger } from '@workspace/airo-ui/components/popover'; import { Tabs, TabsList, TabsTrigger } from '@workspace/airo-ui/components/tabs'; import { differenceInDays } from '@workspace/airo-ui/utils'; +import Link from 'next/link'; import { QRCodeCanvas } from 'qrcode.react'; import { useEffect, useState } from 'react'; import { CopyToClipboard } from 'react-copy-to-clipboard'; + interface SubscribeCardProps { userSubscribeData: API.UserSubscribe; protocol: string[]; @@ -53,7 +55,7 @@ const SubscribeCard = (props: SubscribeCardProps) => { if (list.length > 0) { setUserSubscribeProtocolCurrent(0); } - }, [props.userSubscribeData.token, protocol]); + }, [props.userSubscribeData?.token, protocol]); return (
@@ -69,11 +71,15 @@ const SubscribeCard = (props: SubscribeCardProps) => { {t('totalTraffic')}

- + {userSubscribeData?.token ? ( + + ) : ( + '0.00GB' + )}

@@ -81,9 +87,15 @@ const SubscribeCard = (props: SubscribeCardProps) => { {t('nextResetDays')}

- {userSubscribeData.reset_time - ? differenceInDays(new Date(userSubscribeData.reset_time), new Date()) - : t('noReset')} + {userSubscribeData?.token ? ( + <> + {userSubscribeData.reset_time + ? differenceInDays(new Date(userSubscribeData.reset_time), new Date()) + : t('noReset')} + + ) : ( + 'N/A' + )}

@@ -91,17 +103,28 @@ const SubscribeCard = (props: SubscribeCardProps) => { {t('expirationDays')}

- {userSubscribeData.expire_time - ? differenceInDays(new Date(userSubscribeData.expire_time), new Date()) || - t('unknown') - : t('noLimit')} + {userSubscribeData?.token ? ( + <> + {userSubscribeData.expire_time + ? differenceInDays(new Date(userSubscribeData.expire_time), new Date()) || + t('unknown') + : t('noLimit')} + + ) : ( + 'N/A' + )}

{/* 订阅链接 */} -
+
+
+ + 立即购买订阅 + +
{props.protocol.length > 1 && ( {
-
+
{userSubscribeProtocol[userSubscribeProtocolCurrent]} @@ -203,7 +226,7 @@ const SubscribeCard = (props: SubscribeCardProps) => {
- + {t('resetSubscription')} @@ -231,7 +254,7 @@ const SubscribeCard = (props: SubscribeCardProps) => {
diff --git a/apps/user/app/(main)/(content)/(user)/dashboard/content.tsx b/apps/user/app/(main)/(content)/(user)/dashboard/content.tsx index 6eb95fa..41e798c 100644 --- a/apps/user/app/(main)/(content)/(user)/dashboard/content.tsx +++ b/apps/user/app/(main)/(content)/(user)/dashboard/content.tsx @@ -27,7 +27,6 @@ import { Empty } from '@/components/empty'; import SvgIcon from '@/components/SvgIcon'; import { queryAnnouncement } from '@/services/user/announcement'; import { queryOrderList } from '@/services/user/order'; -import { default as Airo_Empty } from '@workspace/airo-ui/custom-components/empty'; import { formatDate } from '@workspace/airo-ui/utils'; const platforms: (keyof API.ApplicationPlatform)[] = [ @@ -202,20 +201,13 @@ export default function Content() { {t('beginnerTutorial')}
-
- {t('copySubscribeLink')} -
- {userSubscribe?.[0] && data?.protocol ? ( - - ) : ( - - )} + {/* 账户概况 Card */} @@ -264,7 +256,11 @@ export default function Content() { {t('inEffect')} - ) : null} + ) : ( + + 未生效 + + )}
- {userSubscribe?.length ? ( - <> -
- {t('planExpirationTime')} - {formatDate(userSubscribe?.[0]?.expire_time, false)} -
-
- - {userSubscribe?.[0]?.subscribe.name} - -
-
-
- {t('availableDevices')} -
- {Array.from({ length: userSubscribe?.[0]?.subscribe.device_limit }).map( - (_, index) => { - return ( -
1 ? 'bg-[#225BA9]' : 'bg-[#D9D9D9]'}`} - >
- ); - }, - )} -
+
+
+ {t('planExpirationTime')} + {formatDate(userSubscribe?.[0]?.expire_time, false) || '暂无'} +
+
+ + {userSubscribe?.[0]?.subscribe.name ? ( + userSubscribe?.[0]?.subscribe.name + ) : ( + 暂无套餐 + )} + +
+
+
+ {t('availableDevices')} +
+ {Array.from({ length: userSubscribe?.[0]?.subscribe.device_limit || 6 }).map( + (_, index) => { + return ( +
1 ? 'bg-[#225BA9]' : 'bg-[#D9D9D9]'}`} + >
+ ); + }, + )}
+
+ + {t('online')} + {data?.online_device || 0}/{userSubscribe?.[0]?.subscribe.device_limit || 0} + +
+
+
- {t('online')} - {data?.online_device} / {userSubscribe?.[0]?.subscribe.device_limit} + {t('usedTrafficTotalTraffic')} + {userSubscribe?.[0]?.subscribe.device_limit ? ( + <> + + / + + + ) : ( + '0GB/0GB' + )} + + + {t('remaining')} + {100 - + Math.round( + (((userSubscribe?.[0]?.upload || 0) + (userSubscribe?.[0]?.download || 0)) / + (userSubscribe?.[0]?.traffic || 1)) * + 100, + )} + %
-
-
- - {t('usedTrafficTotalTraffic')} - - /{' '} - - - - {t('remaining')} - {100 - - Math.round( - (((userSubscribe?.[0]?.upload || 0) + (userSubscribe?.[0]?.download || 0)) / - (userSubscribe?.[0]?.traffic || 1)) * - 100, - )} - % - -
-
-
-
+
+
- - ) : ( - - )} +
+
{/* 网站公告 Card */} diff --git a/apps/user/app/(main)/(content)/(user)/document/tutorial-button.tsx b/apps/user/app/(main)/(content)/(user)/document/tutorial-button.tsx index 807eeaa..a650597 100644 --- a/apps/user/app/(main)/(content)/(user)/document/tutorial-button.tsx +++ b/apps/user/app/(main)/(content)/(user)/document/tutorial-button.tsx @@ -168,7 +168,7 @@ export function TutorialButton({ items }: { items: Item[] }) { )}
-
+
{item.download ? ( From 5576135726672bfe60db80db7fd0ccd3d6dc101f Mon Sep 17 00:00:00 2001 From: speakeloudest Date: Sun, 5 Oct 2025 08:36:26 -0700 Subject: [PATCH 12/12] =?UTF-8?q?fix:=20admin=E6=8F=90=E4=BA=A4=E6=A0=B7?= =?UTF-8?q?=E5=BC=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index fa4e439..5e118f2 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "ppanel-web", - "version": "1.3.0", + "version": "1.3.1", "private": true, "homepage": "https://github.com/perfect-panel/ppanel-web", "bugs": {