Add version history and bump project version to 0.19.0

This commit is contained in:
linkong
2026-03-25 17:36:18 +08:00
parent 020c1d5051
commit 3fd6cbb6f7
6 changed files with 93 additions and 3 deletions

View File

@@ -1,6 +1,6 @@
{
"name": "planet-frontend",
"version": "1.0.0",
"version": "0.19.0",
"private": true,
"dependencies": {
"@ant-design/icons": "^5.2.6",

View File

@@ -11,6 +11,7 @@ import {
} from '@ant-design/icons'
import { Link, useLocation } from 'react-router-dom'
import { useAuthStore } from '../../stores/auth'
import packageJson from '../../../package.json'
const { Sider, Content } = Layout
const { Text } = Typography
@@ -24,6 +25,7 @@ function AppLayout({ children }: AppLayoutProps) {
const { user, logout } = useAuthStore()
const [collapsed, setCollapsed] = useState(false)
const showBanner = true
const appVersion = `v${packageJson.version}`
const menuItems = [
{ key: '/', icon: <DashboardOutlined />, label: <Link to="/"></Link> },
@@ -74,6 +76,10 @@ function AppLayout({ children }: AppLayoutProps) {
<Text className="dashboard-sider-banner-label"></Text>
<Text strong className="dashboard-sider-banner-value">{user?.username}</Text>
</div>
<div>
<Text className="dashboard-sider-banner-label"></Text>
<Text strong className="dashboard-sider-banner-value">{appVersion}</Text>
</div>
<Button type="primary" danger ghost block onClick={logout}>
退
</Button>