mirror of
https://github.com/antebudimir/feishin.git
synced 2025-12-31 18:13:31 +00:00
fix item playback buttons on search list (#885)
This commit is contained in:
parent
4a3604b1a8
commit
d35e73792f
2 changed files with 3 additions and 4 deletions
|
|
@ -76,8 +76,6 @@ export const useHandlePlayQueueAdd = () => {
|
|||
let songs: QueueSong[] | null = null;
|
||||
let initialSongIndex = 0;
|
||||
|
||||
console.log('options :>> ', options);
|
||||
|
||||
if (byItemType) {
|
||||
let songList: SongListResponse | undefined;
|
||||
const { type: itemType, id } = byItemType;
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@ import { MutableRefObject } from 'react';
|
|||
import { generatePath, useNavigate } from 'react-router';
|
||||
import { useParams, useSearchParams } from 'react-router-dom';
|
||||
import { AppRoute } from '../../../router/routes';
|
||||
import { LibraryItem, QueueSong } from '/@/renderer/api/types';
|
||||
import { LibraryItem, QueueSong, SongListQuery } from '/@/renderer/api/types';
|
||||
import { VirtualGridAutoSizerContainer } from '/@/renderer/components/virtual-grid';
|
||||
import { VirtualTable } from '/@/renderer/components/virtual-table';
|
||||
import { useCurrentSongRowStyles } from '/@/renderer/components/virtual-table/hooks/use-current-song-row-styles';
|
||||
|
|
@ -80,7 +80,7 @@ export const SearchContent = ({ tableRef }: SearchContentProps) => {
|
|||
|
||||
const { rowClassRules } = useCurrentSongRowStyles({ tableRef });
|
||||
|
||||
const tableProps = useVirtualTable({
|
||||
const tableProps = useVirtualTable<SongListQuery>({
|
||||
contextMenu: contextMenuItems(),
|
||||
customFilters: filter,
|
||||
itemType,
|
||||
|
|
@ -96,6 +96,7 @@ export const SearchContent = ({ tableRef }: SearchContentProps) => {
|
|||
key={`table-${itemType}-${tableProps.rowHeight}-${server?.id}`}
|
||||
ref={tableRef}
|
||||
context={{
|
||||
itemType,
|
||||
query: searchParams.get('query'),
|
||||
}}
|
||||
getRowId={(data) => data.data.id}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue