[fix] linting errors
All checks were successful
Dependabot Auto-merge / dependabot (pull_request) Has been skipped

This commit is contained in:
Purp1e
2025-03-13 00:30:41 +08:00
parent d7234ddae9
commit 8822dfb290
4 changed files with 14 additions and 11 deletions

View File

@@ -46,6 +46,7 @@
"@typescript-eslint/no-confusing-void-expression": "off",
"@typescript-eslint/no-unsafe-return": "off",
"@typescript-eslint/no-unsafe-call": "off",
"@typescript-eslint/ban-ts-comment": "off",
"@typescript-eslint/prefer-nullish-coalescing": "off",
"@typescript-eslint/no-unsafe-member-access": "warn",
"jsx-a11y/click-events-have-key-events": "off"

View File

@@ -1,9 +1,9 @@
import { TakeOff } from "@icon-park/react"
import { invoke } from "@tauri-apps/api/core"
import { Card, CardBody, CardHeader, CardIcon } from "../window/Card"
import { steamStore } from "@/store/steam"
import { toolStore } from "@/store/tool"
import { TakeOff } from "@icon-park/react"
import { invoke } from "@tauri-apps/api/core"
import { useSnapshot } from "valtio"
import { Card, CardBody, CardHeader, CardIcon } from "../window/Card"
// import { addToast } from "@heroui/react"
const FastLaunch = () => {
@@ -25,7 +25,7 @@ const FastLaunch = () => {
type="button"
onClick={() =>
invoke("launch_game", {
steamPath: dir + "/steam.exe",
steamPath: `${dir}/steam.exe`,
launchOption: launchOptions[launchIndex] || "",
server: "perfectworld",
})
@@ -38,7 +38,7 @@ const FastLaunch = () => {
type="button"
onClick={() =>
invoke("launch_game", {
steamPath: dir + "/steam.exe",
steamPath: `${dir}/steam.exe`,
launchOption: launchOptions[launchIndex] || "",
server: "worldwide",
})

View File

@@ -63,6 +63,7 @@ const Avatar = () => {
"w-12 h-12 bg-gray-700 rounded-full shadow-2xl cursor-pointer transition active:scale-95 shadow-purple-800",
path.startsWith("/users") && "shadow-sm",
)}
type="button"
>
<img src="favicon.ico" alt="avatar" draggable={false} />
</button>

View File

@@ -1,15 +1,16 @@
import { setValtioPath } from 'tauri-plugin-valtio';
import {appConfigDir} from '@tauri-apps/api/path'
import path from 'path';
// @ts-ignore
import path from "path"
import { appConfigDir } from "@tauri-apps/api/path"
import { setValtioPath } from "tauri-plugin-valtio"
async function init() {
const configDir = await appConfigDir()
const distDir = path.join(configDir, 'cstb')
await setValtioPath(distDir);
const distDir = path.join(configDir, "cstb")
await setValtioPath(distDir)
// console.log('init valtio', distDir);
}
init();
void init()
export const DEFAULT_STORE_CONFIG = {
saveOnChange: true,