✨ feat(ui): display version and git hash in header
Add version info display below "ERP Auto" logo showing format:
${version}(${git-hash})
- Inject __APP_VERSION__ and __GIT_HASH__ via vite define
- Add TypeScript declarations for global constants
- Simplify portable artifact name (remove version)
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -332,12 +332,17 @@ function App(): React.JSX.Element {
|
||||
</div>
|
||||
|
||||
<div
|
||||
className="flex items-center gap-2 text-white font-bold text-lg cursor-pointer"
|
||||
className="flex flex-col cursor-pointer"
|
||||
onClick={() => setCurrentPage('home')}
|
||||
style={{ WebkitAppRegion: 'no-drag' } as any}
|
||||
>
|
||||
<LayoutDashboard size={22} className="text-blue-500" />
|
||||
<span>ERP Auto</span>
|
||||
<div className="flex items-center gap-2 text-white font-bold text-lg">
|
||||
<LayoutDashboard size={22} className="text-blue-500" />
|
||||
<span>ERP Auto</span>
|
||||
</div>
|
||||
<span className="text-xs text-slate-400 ml-7">
|
||||
{__APP_VERSION__}({__GIT_HASH__})
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
3
src/renderer/src/env.d.ts
vendored
3
src/renderer/src/env.d.ts
vendored
@@ -1 +1,4 @@
|
||||
/// <reference types="vite/client" />
|
||||
|
||||
declare const __APP_VERSION__: string
|
||||
declare const __GIT_HASH__: string
|
||||
|
||||
Reference in New Issue
Block a user