Restructure; use DaisyUI

This commit is contained in:
Geomitron
2023-11-28 19:50:45 -06:00
parent 49c3f38f99
commit 2eef4d0bee
727 changed files with 1283 additions and 298840 deletions

View File

@@ -1,20 +1,6 @@
import { VersionResult } from '../../shared/interfaces/songDetails.interface'
import { IPCInvokeHandler } from '../../shared/IPCHandler'
import { serverURL } from '../../shared/Paths'
import { serverURL } from '../../../src-shared/Paths'
/**
* Handles the 'batch-song-details' event.
*/
class BatchSongDetailsHandler implements IPCInvokeHandler<'batch-song-details'> {
event = 'batch-song-details' as const
/**
* @returns an array of all the chart versions with a songID found in `songIDs`.
*/
async handler(songIDs: number[]): Promise<VersionResult[]> {
const response = await fetch(`https://${serverURL}/api/data/song-versions/${songIDs.join(',')}`)
return await response.json()
}
export async function getBatchSongDetails(songIds: number[]) {
const response = await fetch(`https://${serverURL}/api/data/song-versions/${songIds.join(',')}`)
return await response.json()
}
export const batchSongDetailsHandler = new BatchSongDetailsHandler()