Show that no mods are available to download/installed

This commit is contained in:
Lncvrt committed 2026-03-24 18:08:08 -07:00
1 parent 60f9f95be4
commit 6bf2733cec
1 file changed
+18 -2
+18 -2
View File
@@ -105,9 +105,25 @@ export default function ModDownloadsPopup () {
</div> </div>
) : null} ) : null}
<div className='popup-content h-full'> <div className='popup-content h-full'>
{typeof mods == 'number' ? ( {typeof mods == 'number' ||
(!showModInfo &&
mods.filter(v =>
tab == 0
? Object.keys(downloadedVersionsConfig?.mods ?? []).includes(
String(versionInfo?.game + '-' + v.id)
)
: !Object.keys(downloadedVersionsConfig?.mods ?? []).includes(
String(versionInfo?.game + '-' + v.id)
)
).length == 0) ? (
<p className='text-2xl flex justify-center items-center h-full'> <p className='text-2xl flex justify-center items-center h-full'>
{mods == 0 ? 'Loading' : 'Failed to load mods'} {typeof mods == 'number'
? mods == 0
? 'Loading'
: 'Failed to load mods'
: tab == 0
? 'No mods installed'
: 'No mods available to download'}
</p> </p>
) : !showModInfo ? ( ) : !showModInfo ? (
<div className='flex flex-col items-center justify-center gap-2 p-2'> <div className='flex flex-col items-center justify-center gap-2 p-2'>