[feat] adapt steam store + adjust dark mode styles

This commit is contained in:
Purp1e
2025-03-12 13:16:25 +08:00
parent 0c102dfd63
commit 91a003d016
9 changed files with 51 additions and 15 deletions

View File

@@ -2,7 +2,7 @@
import { Home, MonitorOne, Movie, Setting, Terminal, Toolkit } from "@icon-park/react"
import { Button, cn } from "@heroui/react"
import { usePathname, useRouter } from "next/navigation"
import type { ReactNode } from "react"
import { useEffect, type ReactNode } from "react"
// import { platform } from "@tauri-apps/plugin-os"
import { appStore, setVersion } from "@/store/app"
@@ -63,7 +63,11 @@ const Avatar = () => {
}
const SideBar = () => {
appStore.start()
useEffect(() => {
;async () => {
appStore.start()
}
}, [])
const { version } = useSnapshot(appStore.state)
return (
@@ -104,7 +108,12 @@ const SideBar = () => {
<div className="mx-auto text-sm text-center text-zinc-500" data-tauri-drag-region>
<p></p>
<Button variant="light" size="sm" className="mt-0.5 text-zinc-600" onPress={() => setVersion("x.y.z")}>
<Button
variant="light"
size="sm"
className="mt-0.5 text-zinc-600"
onPress={() => setVersion("x.y.z")}
>
{version}
</Button>
</div>