From f63ec718c2b4e28e7df095c4a5623e154ecea8ee Mon Sep 17 00:00:00 2001 From: Matthew Stratford Date: Mon, 31 May 2021 22:48:40 +0100 Subject: [PATCH] Add WIP dummy timeslotid back --- src/App.tsx | 16 ++++++++-------- src/bapsiclesession/index.tsx | 2 +- src/showplanner/state.ts | 1 + 3 files changed, 10 insertions(+), 9 deletions(-) diff --git a/src/App.tsx b/src/App.tsx index 92621ec..c215a68 100644 --- a/src/App.tsx +++ b/src/App.tsx @@ -25,11 +25,18 @@ const App: React.FC = () => { const [inputVal, setInputVal] = useState(""); const force = useForceUpdate(); + const { + currentUser, + userLoading, + currentTimeslot, + timeslotLoading, + } = useSelector((state: RootState) => state.session); + if (process.env.REACT_APP_BAPSICLE_INTERFACE) { if (bapsConnectionState !== "CONNECTED") { return ; } else { - return ; + return ; } } @@ -46,13 +53,6 @@ const App: React.FC = () => { const q = qs.parse(window.location.search, { ignoreQueryPrefix: true }); - const { - currentUser, - userLoading, - currentTimeslot, - timeslotLoading, - } = useSelector((state: RootState) => state.session); - if ( currentUser == null || userLoading || diff --git a/src/bapsiclesession/index.tsx b/src/bapsiclesession/index.tsx index eda87c6..6f467ba 100644 --- a/src/bapsiclesession/index.tsx +++ b/src/bapsiclesession/index.tsx @@ -53,7 +53,7 @@ const SessionHandler: React.FC = function() { switch (connectionState) { case "CONNECTED": - return ; + return ; case "CONNECTING": return ; case "FAILED": diff --git a/src/showplanner/state.ts b/src/showplanner/state.ts index 567d801..88889cf 100644 --- a/src/showplanner/state.ts +++ b/src/showplanner/state.ts @@ -274,6 +274,7 @@ export const setItemPlayed = ( }; export const moveItem = ( + timeslotid: number, itemid: string, to: [number, number] ): AppThunk => async (dispatch, getState) => {