|
@@ -2,11 +2,13 @@ import { AppState } from '@/types'
|
|
|
|
|
|
import { defineStore } from 'pinia'
|
|
|
import { getLanguage } from '@/lang'
|
|
|
+import { isMaxM } from '@/utils'
|
|
|
|
|
|
const useAppStore = defineStore({
|
|
|
id: 'app',
|
|
|
state: (): AppState => ({
|
|
|
device: 'desktop',
|
|
|
+ isMaxM: false,
|
|
|
|
|
|
|
|
|
|
|
@@ -16,6 +18,9 @@ const useAppStore = defineStore({
|
|
|
|
|
|
}),
|
|
|
actions: {
|
|
|
+ updateDevice() {
|
|
|
+ this.isMaxM = isMaxM()
|
|
|
+ },
|
|
|
|
|
|
|
|
|
|