Start working on LibraryView #9

This commit is contained in:
prayag17 committed 2023-04-02 18:07:10 +05:30
1 parent b02b3a95d2
commit 272f74473a
4 files changed
+22 -31

No files matched your search

+7 -7
View File
@@ -21,7 +21,7 @@
"@tanstack/react-query-devtools": "^4.28.0", "@tanstack/react-query-devtools": "^4.28.0",
"blurhash": "^2.0.5", "blurhash": "^2.0.5",
"events": "^3.3.0", "events": "^3.3.0",
"framer-motion": "^10.9.1", "framer-motion": "^10.10.0",
"localforage": "^1.10.0", "localforage": "^1.10.0",
"match-sorter": "^6.3.1", "match-sorter": "^6.3.1",
"notistack": "^3.0.1", "notistack": "^3.0.1",
@@ -2254,9 +2254,9 @@
} }
}, },
"node_modules/framer-motion": { "node_modules/framer-motion": {
"version": "10.9.1", "version": "10.10.0",
"resolved": "https://registry.npmjs.org/framer-motion/-/framer-motion-10.9.1.tgz", "resolved": "https://registry.npmjs.org/framer-motion/-/framer-motion-10.10.0.tgz",
"integrity": "sha512-fuCDRGKOu5n9gN2/R7O22mE+BHMGK5D57S3Oq8n2ITd4aYR7D22QM5I4VPD3CWahNt/lyDUs20u9Aw+6ah9oAQ==", "integrity": "sha512-eCsyOcJimIRbx9KOzBTO3j9u1rF/H8/o/ybizYqdrzHkEeHx9L2NcEfGWfV0OHTc1JV17ECVzuZpomupEJ4+dw==",
"dependencies": { "dependencies": {
"tslib": "^2.4.0" "tslib": "^2.4.0"
}, },
@@ -4642,9 +4642,9 @@
} }
}, },
"framer-motion": { "framer-motion": {
"version": "10.9.1", "version": "10.10.0",
"resolved": "https://registry.npmjs.org/framer-motion/-/framer-motion-10.9.1.tgz", "resolved": "https://registry.npmjs.org/framer-motion/-/framer-motion-10.10.0.tgz",
"integrity": "sha512-fuCDRGKOu5n9gN2/R7O22mE+BHMGK5D57S3Oq8n2ITd4aYR7D22QM5I4VPD3CWahNt/lyDUs20u9Aw+6ah9oAQ==", "integrity": "sha512-eCsyOcJimIRbx9KOzBTO3j9u1rF/H8/o/ybizYqdrzHkEeHx9L2NcEfGWfV0OHTc1JV17ECVzuZpomupEJ4+dw==",
"requires": { "requires": {
"@emotion/is-prop-valid": "^0.8.2", "@emotion/is-prop-valid": "^0.8.2",
"tslib": "^2.4.0" "tslib": "^2.4.0"
+1 -1
View File
@@ -22,7 +22,7 @@
"@tanstack/react-query-devtools": "^4.28.0", "@tanstack/react-query-devtools": "^4.28.0",
"blurhash": "^2.0.5", "blurhash": "^2.0.5",
"events": "^3.3.0", "events": "^3.3.0",
"framer-motion": "^10.9.1", "framer-motion": "^10.10.0",
"localforage": "^1.10.0", "localforage": "^1.10.0",
"match-sorter": "^6.3.1", "match-sorter": "^6.3.1",
"notistack": "^3.0.1", "notistack": "^3.0.1",
+5 -23
View File
@@ -1,12 +1,11 @@
/** @format */ /** @format */
import React, { useState, Suspense } from "react"; import React, { useState } from "react";
import { ThemeProvider } from "@mui/material/styles"; import { ThemeProvider } from "@mui/material/styles";
import { SnackbarProvider } from "notistack"; import { SnackbarProvider } from "notistack";
import { import {
Routes, Routes,
Route, Route,
Navigate,
useNavigate, useNavigate,
useLocation, useLocation,
Outlet, Outlet,
@@ -45,8 +44,10 @@ import {
LoginWithImage, LoginWithImage,
UserLoginManual, UserLoginManual,
} from "./routes/login/root"; } from "./routes/login/root";
import LibraryView from "./routes/library/root.jsx";
import { SideMenu } from "./components/menu/sidemenu.jsx"; import { SideMenu } from "./components/menu/sidemenu.jsx";
import { AppBar } from "./components/appBar/appBar.jsx";
// Fonts // Fonts
import "@fontsource/open-sans"; import "@fontsource/open-sans";
@@ -57,7 +58,6 @@ import { version as appVer } from "../package.json";
import { v4 as uuidv4 } from "uuid"; import { v4 as uuidv4 } from "uuid";
import { delServer, getServer } from "./utils/storage/servers.js"; import { delServer, getServer } from "./utils/storage/servers.js";
import { getUser } from "./utils/storage/user.js"; import { getUser } from "./utils/storage/user.js";
import { AppBar } from "./components/appBar/appBar.jsx";
const jellyfin = new Jellyfin({ const jellyfin = new Jellyfin({
clientInfo: { clientInfo: {
@@ -308,21 +308,6 @@ function App() {
<CssBaseline /> <CssBaseline />
<SideMenu /> <SideMenu />
<AppBar /> <AppBar />
<Suspense
fallback={
<Box
sx={{
display: "flex",
width: "100%",
height: "100vh",
justifyContent: "center",
alignItems: "center",
}}
>
<CircularProgress />
</Box>
}
>
<Routes <Routes
key={location.pathname} key={location.pathname}
location={location} location={location}
@@ -357,7 +342,7 @@ function App() {
/> />
<Route <Route
path="/library/:id" path="/library/:id"
element={<></>} element={<LibraryView />}
/> />
{/* Logical Routes */} {/* Logical Routes */}
@@ -369,13 +354,10 @@ function App() {
<Route <Route
exact exact
path="/login" path="/login"
element={ element={<LoginLogicalRoutes />}
<LoginLogicalRoutes />
}
/> />
</Route> </Route>
</Routes> </Routes>
</Suspense>
</div> </div>
</AnimatePresence> </AnimatePresence>
<ReactQueryDevtools /> <ReactQueryDevtools />
+9
View File
@@ -0,0 +1,9 @@
/** @format */
import { useParams } from "react-router-dom";
const LibraryView = () => {
const { id } = useParams();
return <h1>{id}</h1>;
};
export default LibraryView;