Mission Popup WIP
This commit is contained in:
@@ -58,6 +58,13 @@ interface MapStore {
|
||||
aircraftId: string,
|
||||
tab: MapStore["aircraftTabs"][string],
|
||||
) => void;
|
||||
missionTabs: {
|
||||
[missionId: string]: "home" | "details" | "chat";
|
||||
};
|
||||
setMissionTab: (
|
||||
missionId: string,
|
||||
tab: MapStore["missionTabs"][string],
|
||||
) => void;
|
||||
}
|
||||
|
||||
export const useMapStore = create<MapStore>((set, get) => ({
|
||||
@@ -106,4 +113,12 @@ export const useMapStore = create<MapStore>((set, get) => ({
|
||||
[aircraftId]: tab,
|
||||
},
|
||||
})),
|
||||
missionTabs: {},
|
||||
setMissionTab: (missionId, tab) =>
|
||||
set((state) => ({
|
||||
missionTabs: {
|
||||
...state.missionTabs,
|
||||
[missionId]: tab,
|
||||
},
|
||||
})),
|
||||
}));
|
||||
|
||||
Reference in New Issue
Block a user