Bugfix for null themePlaylists

This commit is contained in:
2026-01-05 21:41:09 -06:00
parent 0df4f28f40
commit 38285943cd
3 changed files with 62 additions and 62 deletions

102
package-lock.json generated
View File

@@ -8,16 +8,16 @@
"name": "triggerfrontend",
"version": "1.0.0",
"dependencies": {
"@gfazioli/mantine-text-animate": "^2.3.9",
"@gfazioli/mantine-text-animate": "^2.3.10",
"@hello-pangea/dnd": "^18.0.1",
"@mantine/core": "^8.3.10",
"@mantine/dates": "^8.3.10",
"@mantine/form": "^8.3.10",
"@mantine/hooks": "^8.3.10",
"@mantine/notifications": "^8.3.10",
"@tanstack/react-query": "^5.90.15",
"@mantine/core": "^8.3.11",
"@mantine/dates": "^8.3.11",
"@mantine/form": "^8.3.11",
"@mantine/hooks": "^8.3.11",
"@mantine/notifications": "^8.3.11",
"@tanstack/react-query": "^5.90.16",
"@tanstack/react-query-devtools": "^5.91.2",
"@tanstack/react-query-persist-client": "^5.90.17",
"@tanstack/react-query-persist-client": "^5.90.18",
"@tanstack/react-table": "^8.21.3",
"idb-keyval": "^6.2.2",
"jotai": "^2.16.1",
@@ -834,9 +834,9 @@
"license": "MIT"
},
"node_modules/@gfazioli/mantine-text-animate": {
"version": "2.3.9",
"resolved": "https://registry.npmjs.org/@gfazioli/mantine-text-animate/-/mantine-text-animate-2.3.9.tgz",
"integrity": "sha512-9M9+NAWxL65rOWeoZZMtwH/dDlLP4ocZiQoC4EW6OFlhGUqr4LxL3nuZ2WrORW0uTlkUmA85lLLFJD+E4KSzSw==",
"version": "2.3.10",
"resolved": "https://registry.npmjs.org/@gfazioli/mantine-text-animate/-/mantine-text-animate-2.3.10.tgz",
"integrity": "sha512-2mN/0dN6NteRNdMEC7wKkycJPwTfSO0MoNBzf00tDUk8sBeMQkV+f4bRLw0F7Z0MnbjSafh1bolzdS0uwKvYRw==",
"peerDependencies": {
"@mantine/core": ">=7.0.0",
"@mantine/hooks": ">=7.0.0",
@@ -911,9 +911,9 @@
}
},
"node_modules/@mantine/core": {
"version": "8.3.10",
"resolved": "https://registry.npmjs.org/@mantine/core/-/core-8.3.10.tgz",
"integrity": "sha512-aKQFETN14v6GtM07b/G5yJneMM1yrgf9mNrTah6GVy5DvQM0AeutITT7toHqh5gxxwzdg/DoY+HQsv5zhqnc5g==",
"version": "8.3.11",
"resolved": "https://registry.npmjs.org/@mantine/core/-/core-8.3.11.tgz",
"integrity": "sha512-FWXp94tiTFdh8BKc7UTNdIuumD96JFxLF/VvUWGRzf5i563Ye0Ma/aZtOBwpdEtdIQkojOhoMMV76k5toOQgEQ==",
"dependencies": {
"@floating-ui/react": "^0.27.16",
"clsx": "^2.1.1",
@@ -923,30 +923,30 @@
"type-fest": "^4.41.0"
},
"peerDependencies": {
"@mantine/hooks": "8.3.10",
"@mantine/hooks": "8.3.11",
"react": "^18.x || ^19.x",
"react-dom": "^18.x || ^19.x"
}
},
"node_modules/@mantine/dates": {
"version": "8.3.10",
"resolved": "https://registry.npmjs.org/@mantine/dates/-/dates-8.3.10.tgz",
"integrity": "sha512-P1uZ+alYGp7fsmkfd+7Fur4AGrqT0X6BWLiVTomzrbyykA+m4TSwPyQjKfsDc7XRqaqx992br/U65T82zy+qGQ==",
"version": "8.3.11",
"resolved": "https://registry.npmjs.org/@mantine/dates/-/dates-8.3.11.tgz",
"integrity": "sha512-e5QBHMpTjKDkYHFEYkD3bho4Kk/M04jmXLu9Txb/XkWVDb5A0CNGg6+A8TinXING4B7kn2dMOLmL3s7r6vnJJA==",
"dependencies": {
"clsx": "^2.1.1"
},
"peerDependencies": {
"@mantine/core": "8.3.10",
"@mantine/hooks": "8.3.10",
"@mantine/core": "8.3.11",
"@mantine/hooks": "8.3.11",
"dayjs": ">=1.0.0",
"react": "^18.x || ^19.x",
"react-dom": "^18.x || ^19.x"
}
},
"node_modules/@mantine/form": {
"version": "8.3.10",
"resolved": "https://registry.npmjs.org/@mantine/form/-/form-8.3.10.tgz",
"integrity": "sha512-TuBmCUIH0qHUig+y9My3bLL9CRoW4g9bijIF6743gqVh0o/daSwplc2TTVMj6sl+F1MR+SJiHtAC8FoR7fdhNw==",
"version": "8.3.11",
"resolved": "https://registry.npmjs.org/@mantine/form/-/form-8.3.11.tgz",
"integrity": "sha512-546npW8gHCXUShVL/OOnKBJ1So5bcKTdmiNxzXn8q2eGhMIB+zdj7/v4QUz2j55OjDRPq0dAVJhzDjLfzeibTg==",
"dependencies": {
"fast-deep-equal": "^3.1.3",
"klona": "^2.0.6"
@@ -956,32 +956,32 @@
}
},
"node_modules/@mantine/hooks": {
"version": "8.3.10",
"resolved": "https://registry.npmjs.org/@mantine/hooks/-/hooks-8.3.10.tgz",
"integrity": "sha512-bv+yYHl+keTIvakiDzVJMIjW+o8/Px0G3EdpCMFG+U2ux6SwQqluqoq+/kqrTtT6RaLvQ0fMxjpIULF2cu/xAg==",
"version": "8.3.11",
"resolved": "https://registry.npmjs.org/@mantine/hooks/-/hooks-8.3.11.tgz",
"integrity": "sha512-WJFKDnJJM2fAOCkrO8qRsi3wDdicSFqElruPj5TEYWDL93vl0pITOyN0oRF93bUtx190waqela3edfGH3r5/1g==",
"peerDependencies": {
"react": "^18.x || ^19.x"
}
},
"node_modules/@mantine/notifications": {
"version": "8.3.10",
"resolved": "https://registry.npmjs.org/@mantine/notifications/-/notifications-8.3.10.tgz",
"integrity": "sha512-0aVpRCyn9u0wuryBnFu1jOwBYw6xGeaNNtTcTUnSvkL6NAypfPon6JG7Wsekf3IuWSTLBjhYaFEIEd4nh7VDpg==",
"version": "8.3.11",
"resolved": "https://registry.npmjs.org/@mantine/notifications/-/notifications-8.3.11.tgz",
"integrity": "sha512-bcFzw9m4uzxHMflNeWqa9imCy8T5mHCAV8WRqzAwK/Yls8GL9uJoQH/e1v6Pl4g4yvBmaF9yUHu7Zq3iyKhHhQ==",
"dependencies": {
"@mantine/store": "8.3.10",
"@mantine/store": "8.3.11",
"react-transition-group": "4.4.5"
},
"peerDependencies": {
"@mantine/core": "8.3.10",
"@mantine/hooks": "8.3.10",
"@mantine/core": "8.3.11",
"@mantine/hooks": "8.3.11",
"react": "^18.x || ^19.x",
"react-dom": "^18.x || ^19.x"
}
},
"node_modules/@mantine/store": {
"version": "8.3.10",
"resolved": "https://registry.npmjs.org/@mantine/store/-/store-8.3.10.tgz",
"integrity": "sha512-38t1UivcucZo9hQq27F/eqR5GvovNs4NHEz6DchOuZzV5IJWqO8+T07ivb8wct47ovYe42rPfLcaOdnIEvMsJA==",
"version": "8.3.11",
"resolved": "https://registry.npmjs.org/@mantine/store/-/store-8.3.11.tgz",
"integrity": "sha512-ku48CzN9HobVUjd7o41voaaHKz2CMrtkk454vwXWAspfbpqR4hklL5zq/MzctETFCG6HBDiPRfZAvNm8WaM3Tw==",
"peerDependencies": {
"react": "^18.x || ^19.x"
}
@@ -1608,9 +1608,9 @@
"license": "MIT"
},
"node_modules/@tanstack/query-core": {
"version": "5.90.15",
"resolved": "https://registry.npmjs.org/@tanstack/query-core/-/query-core-5.90.15.tgz",
"integrity": "sha512-mInIZNUZftbERE+/Hbtswfse49uUQwch46p+27gP9DWJL927UjnaWEF2t3RMOqBcXbfMdcNkPe06VyUIAZTV1g==",
"version": "5.90.16",
"resolved": "https://registry.npmjs.org/@tanstack/query-core/-/query-core-5.90.16.tgz",
"integrity": "sha512-MvtWckSVufs/ja463/K4PyJeqT+HMlJWtw6PrCpywznd2NSgO3m4KwO9RqbFqGg6iDE8vVMFWMeQI4Io3eEYww==",
"funding": {
"type": "github",
"url": "https://github.com/sponsors/tannerlinsley"
@@ -1626,11 +1626,11 @@
}
},
"node_modules/@tanstack/query-persist-client-core": {
"version": "5.91.14",
"resolved": "https://registry.npmjs.org/@tanstack/query-persist-client-core/-/query-persist-client-core-5.91.14.tgz",
"integrity": "sha512-22vWKM2SXU29AUAzCv4pjKWx+mVam5QjPH+XZ1FQeH4DgO9HFPjWN8Bf9NVF2ki8eFGzTy+7FCBylEgV+LZgJw==",
"version": "5.91.15",
"resolved": "https://registry.npmjs.org/@tanstack/query-persist-client-core/-/query-persist-client-core-5.91.15.tgz",
"integrity": "sha512-vnPSfQVo41EKJN8v20nkhWNZPyB1dMJIy5icOvCGzcCJzsmRefYY1owtr63ICOcjOiPPTuNEfPsdjdBhkzYnmA==",
"dependencies": {
"@tanstack/query-core": "5.90.15"
"@tanstack/query-core": "5.90.16"
},
"funding": {
"type": "github",
@@ -1638,11 +1638,11 @@
}
},
"node_modules/@tanstack/react-query": {
"version": "5.90.15",
"resolved": "https://registry.npmjs.org/@tanstack/react-query/-/react-query-5.90.15.tgz",
"integrity": "sha512-uQvnDDcTOgJouNtAyrgRej+Azf0U5WDov3PXmHFUBc+t1INnAYhIlpZtCGNBLwCN41b43yO7dPNZu8xWkUFBwQ==",
"version": "5.90.16",
"resolved": "https://registry.npmjs.org/@tanstack/react-query/-/react-query-5.90.16.tgz",
"integrity": "sha512-bpMGOmV4OPmif7TNMteU/Ehf/hoC0Kf98PDc0F4BZkFrEapRMEqI/V6YS0lyzwSV6PQpY1y4xxArUIfBW5LVxQ==",
"dependencies": {
"@tanstack/query-core": "5.90.15"
"@tanstack/query-core": "5.90.16"
},
"funding": {
"type": "github",
@@ -1669,18 +1669,18 @@
}
},
"node_modules/@tanstack/react-query-persist-client": {
"version": "5.90.17",
"resolved": "https://registry.npmjs.org/@tanstack/react-query-persist-client/-/react-query-persist-client-5.90.17.tgz",
"integrity": "sha512-iipmRT7CpW/Is/RKHXPDuWS0FP7RrmJL/KofNb0aKYMl5dH88R0PZ7N0PvJ44SZCwl44p4VG/4ugGDISutCgtQ==",
"version": "5.90.18",
"resolved": "https://registry.npmjs.org/@tanstack/react-query-persist-client/-/react-query-persist-client-5.90.18.tgz",
"integrity": "sha512-ToVRTVpjzTrd9S/p7JIvGdLs+Xtz9aDMM/7+TQGSV9notY8Jt64irfAAAkZ05syftLKS+3KPgyKAnHcVeKVbWQ==",
"dependencies": {
"@tanstack/query-persist-client-core": "5.91.14"
"@tanstack/query-persist-client-core": "5.91.15"
},
"funding": {
"type": "github",
"url": "https://github.com/sponsors/tannerlinsley"
},
"peerDependencies": {
"@tanstack/react-query": "^5.90.15",
"@tanstack/react-query": "^5.90.16",
"react": "^18 || ^19"
}
},

View File

@@ -10,16 +10,16 @@
"preview": "vite preview"
},
"dependencies": {
"@gfazioli/mantine-text-animate": "^2.3.9",
"@gfazioli/mantine-text-animate": "^2.3.10",
"@hello-pangea/dnd": "^18.0.1",
"@mantine/core": "^8.3.10",
"@mantine/dates": "^8.3.10",
"@mantine/form": "^8.3.10",
"@mantine/hooks": "^8.3.10",
"@mantine/notifications": "^8.3.10",
"@tanstack/react-query": "^5.90.15",
"@mantine/core": "^8.3.11",
"@mantine/dates": "^8.3.11",
"@mantine/form": "^8.3.11",
"@mantine/hooks": "^8.3.11",
"@mantine/notifications": "^8.3.11",
"@tanstack/react-query": "^5.90.16",
"@tanstack/react-query-devtools": "^5.91.2",
"@tanstack/react-query-persist-client": "^5.90.17",
"@tanstack/react-query-persist-client": "^5.90.18",
"@tanstack/react-table": "^8.21.3",
"idb-keyval": "^6.2.2",
"jotai": "^2.16.1",

View File

@@ -81,7 +81,7 @@ function App() {
);
useEffect(() => {
if (allThemes && themeName && personalData) {
if (allThemes && themeName && personalData && isThemePlaylistsFetched) {
if (currentThemePlaylist === 'All') {
if (themeName === 'random') {
handleThemeChange(allThemes, false);
@@ -91,7 +91,7 @@ function App() {
}
} else if (currentThemePlaylist === 'Time of Day') {
const themeList = JSON.parse(
themePlaylists.find((t: ThemePlaylist) => t.name === currentThemePlaylist)
themePlaylists?.find((t: ThemePlaylist) => t.name === currentThemePlaylist)
.themeList,
);
setTheme(
@@ -112,7 +112,7 @@ function App() {
);
} else {
const themeList = JSON.parse(
themePlaylists.find((t: ThemePlaylist) => t.name === currentThemePlaylist)
themePlaylists?.find((t: ThemePlaylist) => t.name === currentThemePlaylist)
.themeList,
);
const filteredThemes = allThemes.filter((t: Theme) => themeList.includes(t.id));