Sign in

zengzy / hhrcs_web · Files

Logo

GitLab

  • Back to dashboard
  • Project
  • Activity
  • Files
  • Commits
  • Network
  • Graphs
  • Milestones
  • Issues 0
  • Merge Requests 0
  • Labels
  • Wiki
  • hhrcs_web
  • src
  • stores
  • global-store.ts
  • Init
    58f2e20d
    zengzy authored
    2026-01-12 17:23:34 +0800  
    Browse Code ยป
global-store.ts 273 Bytes
Edit Raw Blame History
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
import { defineStore } from 'pinia'

export const useGlobalStore = defineStore('global', {
  state: () => {
    return {
      isSidebarMinimized: false,
    }
  },

  actions: {
    toggleSidebar() {
      this.isSidebarMinimized = !this.isSidebarMinimized
    },
  },
})