邀请链接替换ios
All checks were successful
site-dist-deploy / build-and-deploy (push) Successful in 1m47s

This commit is contained in:
speakeloudest 2026-03-30 06:36:30 +03:00
parent 1d88c4ea6b
commit 681ad15228
2 changed files with 15 additions and 8 deletions

View File

@ -64,7 +64,7 @@ import AndroidIcon from './AndroidIcon.svg?component'
import request from '@/utils/request' import request from '@/utils/request'
import {computed, ref, onMounted} from "vue"; import {computed, ref, onMounted} from "vue";
import {getAllQueryString} from "@/utils/url-utils.ts"; import {getAllQueryString} from "@/utils/url-utils";
const downLoadWin = ref('') const downLoadWin = ref('')
const downLoadMac = ref('') const downLoadMac = ref('')
@ -114,12 +114,19 @@ request.get('/api/v1/common/client/download', {
downLoadWin.value = res.url downLoadWin.value = res.url
}) })
const allDownloadOptions = computed(() => [ const allDownloadOptions = computed(() => {
{ key: 'win', mainIcon: Icon1, secondaryIcon: WinIcon, link: downLoadWin.value, label: 'Windows', id: 'downloadButton_win' }, const ic = getAllQueryString('ic')
{ key: 'mac', mainIcon: Icon3, secondaryIcon: MacIcon, label: 'macOS', link: `https://hifastvpn.go.link?adj_t=1xf6e7ru&inviteCode=${getAllQueryString('ic')}` }, const androidLink = currentPlatform.value === 'android'
{ key: 'ios', mainIcon: Icon2, secondaryIcon: AppleIcon, label: 'iOS', link: `https://hifastvpn.go.link?adj_t=1xf6e7ru&inviteCode=${getAllQueryString('ic')}` }, ? `https://hifastvpn.go.link?adj_t=1xf6e7ru&inviteCode=${ic}`
{ key: 'android', mainIcon: Icon4, secondaryIcon: AndroidIcon, label: 'Android', link: `https://hifastvpn.go.link?adj_t=1xf6e7ru&inviteCode=${getAllQueryString('ic')}`, }, : 'https://api.hifast.biz/v1/common/client/download/file/Hi%E5%BF%ABVPN-android-1.0.0.apk'
])
return [
{ key: 'win', mainIcon: Icon1, secondaryIcon: WinIcon, link: downLoadWin.value, label: 'Windows', id: 'downloadButton_win' },
{ key: 'mac', mainIcon: Icon3, secondaryIcon: MacIcon, label: 'macOS', link: `https://hifastvpn.go.link?adj_t=1xf6e7ru&inviteCode=${ic}` },
{ key: 'ios', mainIcon: Icon2, secondaryIcon: AppleIcon, label: 'iOS', link: `https://hifastvpn.go.link?adj_t=1xf6e7ru&inviteCode=${ic}` },
{ key: 'android', mainIcon: Icon4, secondaryIcon: AndroidIcon, label: 'Android', link: androidLink },
]
})
const mainButton = computed(() => { const mainButton = computed(() => {
return allDownloadOptions.value.find(opt => opt.key === currentPlatform.value) || allDownloadOptions.value[0] return allDownloadOptions.value.find(opt => opt.key === currentPlatform.value) || allDownloadOptions.value[0]

View File

@ -59,7 +59,7 @@
<script setup lang="ts"> <script setup lang="ts">
import { ref, onMounted, onUnmounted, computed } from 'vue'; import { ref, onMounted, onUnmounted, computed } from 'vue';
import { getAllQueryString } from '@/utils/url-utils.ts'; import { getAllQueryString } from '@/utils/url-utils';
// Import avatars // Import avatars
import avatar1 from './avatars/avatar1.png'; import avatar1 from './avatars/avatar1.png';