diff --git a/ui/package.json b/ui/package.json index 0337fc3..8123ec6 100644 --- a/ui/package.json +++ b/ui/package.json @@ -5,28 +5,22 @@ "private": true, "dependencies": { "@chakra-ui/react": "^1.7.3", - "@emotion/react": "11", - "@emotion/styled": "11", - "@testing-library/jest-dom": "^5.15.0", - "@testing-library/react": "^12.1.2", - "@testing-library/user-event": "^12.1.10", - "@types/jest": "^26.0.15", + "@emotion/react": "^11", + "@emotion/styled": "^11", "@types/node": "^16.11.9", "@types/react": "^17.0.35", "@types/react-dom": "^17.0.11", - "framer-motion": "4", + "framer-motion": "4.1.17", "react": "^17.0.2", "react-dom": "^17.0.2", + "react-router-dom": "6", "react-scripts": "4.0.3", - "typescript": "^4.5.2", - "web-vitals": "^2.1.2" + "typescript": "^4.5.2" }, "scripts": { "start": "cross-env PUBLIC_URL=/ craco start", "start:game": "cross-env IN_GAME_DEV=1 craco start", - "build": "craco build", - "test": "craco test", - "eject": "react-scripts eject" + "build": "craco build" }, "eslintConfig": { "extends": [ @@ -47,7 +41,7 @@ ] }, "devDependencies": { - "craco": "^0.0.3", + "@craco/craco": "^6.4.3", "cross-env": "^7.0.3" } } diff --git a/ui/src/components/App.css b/ui/src/components/App.css deleted file mode 100644 index e69de29..0000000 diff --git a/ui/src/components/App.tsx b/ui/src/components/App.tsx index 0556a36..287cb62 100644 --- a/ui/src/components/App.tsx +++ b/ui/src/components/App.tsx @@ -1,8 +1,9 @@ -import './App.css'; import { Center, Box } from '@chakra-ui/react'; import { debugData } from '../utils/debugData'; import TopBar from './NavBars/TopBar'; import SideBar from './NavBars/SideBar'; +import { Routes, Route } from 'react-router-dom'; +import Resource from './Resource'; debugData([ { diff --git a/ui/src/components/Resource.tsx b/ui/src/components/Resource.tsx new file mode 100644 index 0000000..14f7d7b --- /dev/null +++ b/ui/src/components/Resource.tsx @@ -0,0 +1,10 @@ +import { useParams } from "react-router-dom"; + +const Resource = () => { + + const { resource } = useParams(); + + return