Contextapi fixes

This commit is contained in:
Frikky
2024-10-18 13:43:10 +02:00
parent 61a5489628
commit 6ee9ab4417
3 changed files with 2 additions and 26 deletions
+1 -1
View File
@@ -13,7 +13,7 @@ COPY package.json /usr/src/app/package.json
#RUN yarn config set "strict-ssl" false -g
#RUN yarn install --network-timeout 1000000
RUN npm install --legacy-peer-deps
RUN npm install --timeout=60000 --legacy-peer-deps
# copy only required files to not trigger rebuilding every time
COPY ./certs /usr/src/app/certs/
+1 -2
View File
@@ -1,10 +1,9 @@
{
"name": "shuffler",
"homepage": "https://shuffler.io",
"version": "1.4.0",
"version": "2.0.0",
"private": true,
"dependencies": {
"@babel/plugin-proposal-class-properties": "^7.18.6",
"@codemirror/commands": "^6.2.4",
"@codemirror/lang-python": "^6.1.3",
"@emotion/react": "^11.11.1",
-23
View File
@@ -1,23 +0,0 @@
import { createContext, useState } from 'react';
export const Context = createContext();
export const AppContext =(props) => {
// Left side bar global states
const [searchBarModalOpen, setSearchBarModalOpen] = useState(false);
const [leftSideBarOpenByClick, setLeftSideBarOpenByClick] = useState(false);
return (
<Context.Provider value={{
searchBarModalOpen,
setSearchBarModalOpen,
leftSideBarOpenByClick,
setLeftSideBarOpenByClick
}}>
{props.children}
</Context.Provider>
)
}