feat(fe): add app version display in sidebar footer
- Display app version (v0.1.0 or VITE_APP_VERSION) in sidebar footer - Hidden when sidebar is collapsed - Positioned above Help/Settings buttons This provides system version visibility without requiring footer. Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
This commit is contained in:
@@ -3,6 +3,8 @@ import { ref, computed, onMounted, watch } from 'vue'
|
|||||||
import { useRouter, useRoute } from 'vue-router'
|
import { useRouter, useRoute } from 'vue-router'
|
||||||
import { useAnimatedCollapse } from '../composables/useAnimatedCollapse'
|
import { useAnimatedCollapse } from '../composables/useAnimatedCollapse'
|
||||||
|
|
||||||
|
const appVersion = import.meta.env.VITE_APP_VERSION ?? '0.1.0'
|
||||||
|
|
||||||
interface MenuItem {
|
interface MenuItem {
|
||||||
id: string
|
id: string
|
||||||
label: string
|
label: string
|
||||||
@@ -194,6 +196,9 @@ const sidebarClass = computed(() => ({
|
|||||||
|
|
||||||
<!-- Sidebar footer -->
|
<!-- Sidebar footer -->
|
||||||
<div class="ks-sidebar__footer">
|
<div class="ks-sidebar__footer">
|
||||||
|
<div v-if="!collapsed" class="ks-sidebar__version">
|
||||||
|
v{{ appVersion }}
|
||||||
|
</div>
|
||||||
<button
|
<button
|
||||||
type="button"
|
type="button"
|
||||||
class="ks-sidebar__footer-btn"
|
class="ks-sidebar__footer-btn"
|
||||||
@@ -370,8 +375,9 @@ const sidebarClass = computed(() => ({
|
|||||||
padding: var(--spacing-3);
|
padding: var(--spacing-3);
|
||||||
border-top: 1px solid var(--color-border-primary);
|
border-top: 1px solid var(--color-border-primary);
|
||||||
display: flex;
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
gap: var(--spacing-2);
|
gap: var(--spacing-2);
|
||||||
justify-content: center;
|
align-items: center;
|
||||||
}
|
}
|
||||||
|
|
||||||
.ks-sidebar__footer-btn {
|
.ks-sidebar__footer-btn {
|
||||||
|
|||||||
Reference in New Issue
Block a user