feat: add user manager
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
import { query } from '@/modules/query';
|
||||
import { message } from 'antd';
|
||||
import { create } from 'zustand';
|
||||
import { message } from '@/modules/message';
|
||||
export const getIsMac = async () => {
|
||||
// @ts-ignore
|
||||
const userAgentData = navigator.userAgentData;
|
||||
@@ -37,7 +37,7 @@ export const usePlatformStore = create<PlatfromStore>((set) => {
|
||||
init: async () => {
|
||||
const mac = await getIsMac();
|
||||
// @ts-ignore
|
||||
const isElectron = getIsElectron()
|
||||
const isElectron = getIsElectron();
|
||||
set({ isMac: isElectron && mac, isElectron: isElectron, mount: true });
|
||||
},
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user