Bug fixes

This commit is contained in:
Sean Edmunds
2025-06-19 15:50:00 -05:00
parent 776e075073
commit 07c0a1df56
3 changed files with 22 additions and 6 deletions

View File

@@ -77,7 +77,7 @@ function SettingsButton() {
body: selectedClient || wolClientData?.[0], body: selectedClient || wolClientData?.[0],
}); });
}; };
console.log(themePlaylistData);
useEffect(() => { useEffect(() => {
if (appCategoryData) { if (appCategoryData) {
const list: [any] = appCategoryData.map((category: AppCategory) => { const list: [any] = appCategoryData.map((category: AppCategory) => {
@@ -295,14 +295,29 @@ function SettingsButton() {
placeholder='Pick a playlist...' placeholder='Pick a playlist...'
value={currentThemePlaylist} value={currentThemePlaylist}
data={[ data={[
'All', { value: 'All', label: 'All' },
'Backgrounds', {
'No Backgrounds', value: 'Backgrounds',
label: 'Backgrounds',
disabled:
allThemes.filter(
(a: any) => !a.backgroundImage.toLowerCase().includes('none'),
).length === 0,
},
{
value: 'No Backgrounds',
label: 'No Backgrounds',
disabled:
allThemes.filter(
(a: any) => !a.backgroundImage.toLowerCase().includes('none'),
).length !== 0,
},
...(themePlaylistData ...(themePlaylistData
?.map((playlist: ThemePlaylist) => { ?.map((playlist: ThemePlaylist) => {
return { return {
value: playlist.name, value: playlist.name,
label: playlist.name, label: playlist.name,
disabled: JSON.parse(playlist.themeList).length === 0,
}; };
}) })
.toSorted((a: ComboboxItem, b: ComboboxItem) => .toSorted((a: ComboboxItem, b: ComboboxItem) =>

View File

@@ -6,8 +6,8 @@ function NoItemsFound() {
<Card <Card
className={cardClasses.settingsItem} className={cardClasses.settingsItem}
classNames={cardClasses} classNames={cardClasses}
w={'50%'} w={'40rem'}
h={'100%'} h={'10rem'}
p={'xl'} p={'xl'}
m={'xl'} m={'xl'}
style={{ display: 'flex', justifyContent: 'center', alignItems: 'center' }} style={{ display: 'flex', justifyContent: 'center', alignItems: 'center' }}

View File

@@ -141,6 +141,7 @@ function ThemePlaylistCard({
setCurrentThemePlaylist(cardPlaylist.name); setCurrentThemePlaylist(cardPlaylist.name);
setThemeName('random'); setThemeName('random');
}} }}
disabled={themeList.length === 0}
> >
{hover && <Overlay opacity={0.5} zIndex={1} />} {hover && <Overlay opacity={0.5} zIndex={1} />}
<Stack h={'100%'} w={'100%'} align='center' mt={'.75rem'}> <Stack h={'100%'} w={'100%'} align='center' mt={'.75rem'}>