diff --git a/package-lock.json b/package-lock.json
index af9b9be..f9168cb 100644
--- a/package-lock.json
+++ b/package-lock.json
@@ -35,6 +35,7 @@
"qs": "^6.11.0",
"react": "^18.2.0",
"react-dom": "^18.1.0",
+ "react-icons": "^4.4.0",
"react-infinite-scroller": "^1.2.6",
"react-intl": "^6.0.5",
"react-jinke-music-player": "^4.24.2",
@@ -14119,9 +14120,9 @@
}
},
"node_modules/plex-api-oauth": {
- "version": "1.1.114",
- "resolved": "https://registry.npmjs.org/plex-api-oauth/-/plex-api-oauth-1.1.114.tgz",
- "integrity": "sha512-oru0+xa/65fVQNJrt236VhYacGO2y5o8dgkqVhR2yf79txNESVIP+5We/HLeaRflEV+kuP5O2zuUg8tyZQ0IWQ==",
+ "version": "1.1.116",
+ "resolved": "https://registry.npmjs.org/plex-api-oauth/-/plex-api-oauth-1.1.116.tgz",
+ "integrity": "sha512-bj509pQ4YVvkn1kytMUd8bvMqOAn7Q1VunGn+abX/yDCTjF7z9H3qyDLNBRNy2VhQ7lGSSFQE4LHJ//NXJZxDA==",
"dependencies": {
"axios": "^0.27.2",
"plex-oauth": "^2.0.2",
@@ -15186,6 +15187,14 @@
"react-dom": ">= 16.3.0"
}
},
+ "node_modules/react-icons": {
+ "version": "4.4.0",
+ "resolved": "https://registry.npmjs.org/react-icons/-/react-icons-4.4.0.tgz",
+ "integrity": "sha512-fSbvHeVYo/B5/L4VhB7sBA1i2tS8MkT0Hb9t2H1AVPkwGfVHLJCqyr2Py9dKMxsyM63Eng1GkdZfbWj+Fmv8Rg==",
+ "peerDependencies": {
+ "react": "*"
+ }
+ },
"node_modules/react-infinite-scroller": {
"version": "1.2.6",
"resolved": "https://registry.npmjs.org/react-infinite-scroller/-/react-infinite-scroller-1.2.6.tgz",
@@ -29230,9 +29239,9 @@
"integrity": "sha512-Igl37++MSa+4H8LNP3Ene9GU0e1YypmXvFVNvVUwoAx44e74jbUlJXy4Q5rLSBisn0O2lBKdE6VkFIwrDl+UnQ=="
},
"plex-api-oauth": {
- "version": "1.1.114",
- "resolved": "https://registry.npmjs.org/plex-api-oauth/-/plex-api-oauth-1.1.114.tgz",
- "integrity": "sha512-oru0+xa/65fVQNJrt236VhYacGO2y5o8dgkqVhR2yf79txNESVIP+5We/HLeaRflEV+kuP5O2zuUg8tyZQ0IWQ==",
+ "version": "1.1.116",
+ "resolved": "https://registry.npmjs.org/plex-api-oauth/-/plex-api-oauth-1.1.116.tgz",
+ "integrity": "sha512-bj509pQ4YVvkn1kytMUd8bvMqOAn7Q1VunGn+abX/yDCTjF7z9H3qyDLNBRNy2VhQ7lGSSFQE4LHJ//NXJZxDA==",
"requires": {
"axios": "^0.27.2",
"plex-oauth": "^2.0.2",
@@ -29968,6 +29977,12 @@
"prop-types": "^15.8.1"
}
},
+ "react-icons": {
+ "version": "4.4.0",
+ "resolved": "https://registry.npmjs.org/react-icons/-/react-icons-4.4.0.tgz",
+ "integrity": "sha512-fSbvHeVYo/B5/L4VhB7sBA1i2tS8MkT0Hb9t2H1AVPkwGfVHLJCqyr2Py9dKMxsyM63Eng1GkdZfbWj+Fmv8Rg==",
+ "requires": {}
+ },
"react-infinite-scroller": {
"version": "1.2.6",
"resolved": "https://registry.npmjs.org/react-infinite-scroller/-/react-infinite-scroller-1.2.6.tgz",
diff --git a/package.json b/package.json
index 033775a..9866fcc 100644
--- a/package.json
+++ b/package.json
@@ -47,6 +47,7 @@
"start:preload": "cross-env NODE_ENV=development TS_NODE_TRANSPILE_ONLY=true webpack --config ./.erb/configs/webpack.config.preload.dev.ts",
"start:renderer": "cross-env NODE_ENV=development TS_NODE_TRANSPILE_ONLY=true webpack serve --config ./.erb/configs/webpack.config.renderer.dev.ts",
"test": "jest",
+ "predeploy": "npm run build",
"deploy": "gh-pages -d './release/app/dist/renderer'"
},
"lint-staged": {
@@ -137,6 +138,7 @@
"qs": "^6.11.0",
"react": "^18.2.0",
"react-dom": "^18.1.0",
+ "react-icons": "^4.4.0",
"react-infinite-scroller": "^1.2.6",
"react-intl": "^6.0.5",
"react-jinke-music-player": "^4.24.2",
diff --git a/src/renderer/App.css b/src/renderer/App.css
index 0959e0e..9a9e0af 100644
--- a/src/renderer/App.css
+++ b/src/renderer/App.css
@@ -69,4 +69,12 @@ a:hover {
.site-layout .site-layout-background {
background: #fff;
-}
\ No newline at end of file
+}
+
+.container {
+ -ms-overflow-style: none; /* Internet Explorer 10+ */
+ scrollbar-width: none; /* Firefox */
+}
+.container::-webkit-scrollbar {
+ display: none; /* Safari and Chrome */
+}
diff --git a/src/renderer/App.jsx b/src/renderer/App.jsx
index ed3374d..829564e 100644
--- a/src/renderer/App.jsx
+++ b/src/renderer/App.jsx
@@ -22,6 +22,8 @@ import ListItemText from '@mui/material/ListItemText';
import HomeIcon from '@mui/icons-material/Home';
import LibraryMusicIcon from '@mui/icons-material/LibraryMusic';
import FeaturedPlayListIcon from '@mui/icons-material/FeaturedPlayList';
+import AlbumIcon from '@mui/icons-material/Album';
+import MusicNoteIcon from '@mui/icons-material/MusicNote';
import SettingsIcon from '@mui/icons-material/Settings';
import LockOpenIcon from '@mui/icons-material/LockOpen';
import DarkModeIcon from '@mui/icons-material/DarkMode';
@@ -49,6 +51,12 @@ import {
Stack,
ImageList,
ImageListItem,
+ Skeleton,
+ Snackbar,
+ Alert,
+ Grow,
+ Slide,
+ SnackbarContent,
} from '@mui/material';
import Table from '@mui/material/Table';
import TableBody from '@mui/material/TableBody';
@@ -77,6 +85,8 @@ const drawerWidth = 240;
const iconindex = {
Home: ,
Library: ,
+ Album: ,
+ Song: ,
Playlists: ,
Settings: ,
};
@@ -115,6 +125,7 @@ function App() {
const [query, setQuery] = useState('');
const [pageNumber, setPageNumber] = useState(0);
const [isLoading, setIsLoading] = useState(false);
+ const [isRefreshing, setIsRefreshing] = useState(true);
const [topic, setTopic] = useState();
function handleSearch(event) {
@@ -154,6 +165,10 @@ function App() {
console.log('Theme');
console.log(activeTheme);
+ function SlideTransition(props) {
+ return ;
+ }
+
async function PlexLoginButton() {
const tempPlexTVAuthToken = await PlexLogin(plexClientInformation);
const tempPlexTVUserData = await GetPlexUserData(
@@ -195,6 +210,7 @@ function App() {
setPlexServers(tempPlexServers);
setPlexTVUserData(tempPlexTVUserData);
setPlexLibraries(tempPlexLibraries);
+ setIsRefreshing(false);
}
// useEffect(() => {
@@ -211,6 +227,21 @@ function App() {
// setSearchData({ searchItems, searchHasMore, searchLoading, searchError });
// }, [pageNumber, topic, query, plexSessionData]);
+ function ShowArtist(Obj) {
+ setActiveArtist(Obj);
+ setActivePage(7);
+ }
+
+ function ShowAlbum(Obj) {
+ setActiveAlbum(Obj);
+ setActivePage(8);
+ }
+
+ function ShowPlaylist(Obj) {
+ setActivePlaylist(Obj);
+ setActivePage(9);
+ }
+
async function UpdateLibrary() {
setIsLoading(true);
let returnObject = await GetLibraryPages(
@@ -218,7 +249,7 @@ function App() {
plexLibraries,
topic,
pageNumber,
- 50
+ 100
);
console.log(returnObject);
returnObject.items = [...new Set([...libraryItems, ...returnObject.items])];
@@ -254,6 +285,7 @@ function App() {
}, [pageNumber, plexServers, plexLibraries, topic]);
useEffect(() => {
+ setIsRefreshing(true);
Refresh();
}, []);
@@ -332,6 +364,7 @@ function App() {
{
setActivePage(0);
setPageNumber(0);
@@ -344,6 +377,7 @@ function App() {
{
setActivePage(1);
setPageNumber(0);
@@ -356,6 +390,7 @@ function App() {
{
setActivePage(2);
topic !== 'artists' && setLibraryItems([]);
@@ -370,6 +405,7 @@ function App() {
{
setActivePage(2);
topic !== 'albums' && setLibraryItems([]);
@@ -377,13 +413,14 @@ function App() {
setTopic('albums');
}}
>
- {iconindex.Library}
+ {iconindex.Album}
{
setActivePage(2);
topic !== 'songs' && setLibraryItems([]);
@@ -391,13 +428,14 @@ function App() {
setTopic('songs');
}}
>
- {iconindex.Library}
+ {iconindex.Song}
{
setActivePage(5);
setPageNumber(0);
@@ -410,6 +448,7 @@ function App() {
{
setActivePage(6);
setPageNumber(0);
@@ -425,7 +464,7 @@ function App() {
hidden={isHidden(0)}
component="main"
sx={{
- overflow: 'hidden',
+ overflow: 'auto',
flexGrow: 1,
maxWidth: self.innerWidth - drawerWidth,
bgcolor: 'background.default',
@@ -444,9 +483,10 @@ function App() {
{Obj.title}
{
currentTarget.onerror = null; // prevents looping
@@ -470,7 +511,13 @@ function App() {
}}
/>
- {listItem.title}
+
+ {listItem.title}
+
@@ -590,6 +637,19 @@ function App() {
);
})}
+ {isLoading &&
+ [0, 1, 2, 3].map((Obj, index) => {
+ return (
+
+
+
+ );
+ })}
@@ -662,7 +722,10 @@ function App() {
action={