🌱 微改

This commit is contained in:
BTMuli
2023-08-30 09:25:55 +08:00
parent 2cac0c95bd
commit d64cab8b4e
4 changed files with 12 additions and 10 deletions

View File

@@ -33,7 +33,7 @@
"https://act-webstatic.mihoyo.com/*",
"https://sdk-webstatic.mihoyo.com/*",
"https://homa.snapgenshin.com/*",
"https://help.tencentbot.top/geetest2/*"
"https://enka-api.hut.ao/*"
]
},
"shell": {

View File

@@ -71,7 +71,7 @@
v-for="achievement in renderAchievement"
:key="achievement.id"
class="card-right"
:style="{ Transform: `translateY(${translateY})` }"
:style="{ transform: `translateY(${translateY})` }"
>
<div v-if="achievement.progress !== 0" class="achievement-progress">
{{ achievement.progress }}

View File

@@ -2,11 +2,11 @@
* @file web request getSyncAvatarDetail.ts
* @description 获取同步角色详情相关请求函数
* @author BTMuli <bt-muli@outlook.com>
* @since Alpha v0.2.1
* @since Alpha v0.2.3
*/
// tauri
import { http } from "@tauri-apps/api";
import { app, http } from "@tauri-apps/api";
// api
import TGApi from "../api/TGApi";
// utils
@@ -14,7 +14,7 @@ import TGUtils from "../utils/TGUtils";
/**
* @description 获取同步角色详情
* @since Alpha v0.2.1
* @since Alpha v0.2.3
* @param {TGApp.BBS.Constant.CookieGroup2} cookie cookie
* @param {string} uid 用户 uid
* @param {number} avatarId 角色 id
@@ -35,8 +35,9 @@ async function getSyncAvatarDetail(
account_id: cookie.account_id,
cookie_token: cookie.cookie_token,
};
const version = await app.getVersion();
const header = {
"User-Agent": "Tauri.Genshin/0.2.1",
"User-Agent": `Tauri.Genshin/${version}`,
Referer: "https://webstatic.mihoyo.com/",
Cookie: TGUtils.Tools.transCookie(ck),
};

View File

@@ -2,11 +2,11 @@
* @file web request getSyncAvatarListAll.ts
* @description 获取同步角色列表请求
* @author BTMuli <bt-muli@outlook.com>
* @since Alpha v0.2.1
* @since Alpha v0.2.3
*/
// tauri
import { http } from "@tauri-apps/api";
import { app, http } from "@tauri-apps/api";
// api
import TGApi from "../api/TGApi";
// utils
@@ -14,7 +14,7 @@ import TGUtils from "../utils/TGUtils";
/**
* @description 获取同步角色列表请求
* @since Alpha v0.2.1
* @since Alpha v0.2.3
* @param {Record<string,string>} cookie cookie
* @param {string} uid 用户 uid
* @param {number} page 页码
@@ -31,8 +31,9 @@ async function getSyncAvatarList(
region: TGUtils.Tools.getServerByUid(uid),
page,
};
const version = await app.getVersion();
const header = {
"User-Agent": "Tauri.Genshin/0.2.1",
"User-Agent": `Tauri.Genshin/${version}`,
Referer: "https://webstatic.mihoyo.com/",
Cookie: TGUtils.Tools.transCookie(cookie),
};