From b5ad30a9bc8b1f268cd0b50ce164c98ed1a28490 Mon Sep 17 00:00:00 2001 From: jeffvli Date: Sun, 8 Jan 2023 02:13:39 -0800 Subject: [PATCH] Fix header being squished by table --- .../components/playlist-detail-song-list-content.tsx | 11 ++++++++--- .../routes/playlist-detail-song-list-route.tsx | 11 ++++------- 2 files changed, 12 insertions(+), 10 deletions(-) diff --git a/src/renderer/features/playlists/components/playlist-detail-song-list-content.tsx b/src/renderer/features/playlists/components/playlist-detail-song-list-content.tsx index eef06feb..c92adb54 100644 --- a/src/renderer/features/playlists/components/playlist-detail-song-list-content.tsx +++ b/src/renderer/features/playlists/components/playlist-detail-song-list-content.tsx @@ -8,7 +8,12 @@ import type { RowDoubleClickedEvent, } from '@ag-grid-community/core'; import type { AgGridReact as AgGridReactType } from '@ag-grid-community/react/lib/agGridReact'; -import { getColumnDefs, TablePagination, VirtualTable } from '/@/renderer/components'; +import { + getColumnDefs, + TablePagination, + VirtualGridAutoSizerContainer, + VirtualTable, +} from '/@/renderer/components'; import { useCurrentServer, usePlaylistDetailStore, @@ -185,7 +190,7 @@ export const PlaylistDetailSongListContent = ({ tableRef }: PlaylistDetailConten }; return ( - <> + )} - + ); }; diff --git a/src/renderer/features/playlists/routes/playlist-detail-song-list-route.tsx b/src/renderer/features/playlists/routes/playlist-detail-song-list-route.tsx index f49ecc3a..05843ae7 100644 --- a/src/renderer/features/playlists/routes/playlist-detail-song-list-route.tsx +++ b/src/renderer/features/playlists/routes/playlist-detail-song-list-route.tsx @@ -1,6 +1,6 @@ import { useRef, useState } from 'react'; import type { AgGridReact as AgGridReactType } from '@ag-grid-community/react/lib/agGridReact'; -import { Group, Stack } from '@mantine/core'; +import { Group } from '@mantine/core'; import { closeAllModals, openModal } from '@mantine/modals'; import { AnimatePresence, motion, Variants } from 'framer-motion'; import { RiArrowDownSLine, RiArrowUpSLine } from 'react-icons/ri'; @@ -13,7 +13,7 @@ import { usePlaylistDetail } from '/@/renderer/features/playlists/queries/playli import { useCreatePlaylist } from '/@/renderer/features/playlists/mutations/create-playlist-mutation'; import { AppRoute } from '/@/renderer/router/routes'; import { useDeletePlaylist } from '/@/renderer/features/playlists/mutations/delete-playlist-mutation'; -import { Button, Paper, Text, toast } from '/@/renderer/components'; +import { Button, Paper, Text, toast, VirtualGridContainer } from '/@/renderer/components'; import { SaveAsPlaylistForm } from '/@/renderer/features/playlists/components/save-as-playlist-form'; import { useCurrentServer } from '/@/renderer/store'; import { ServerType } from '/@/renderer/api/types'; @@ -137,10 +137,7 @@ const PlaylistDetailSongListRoute = () => { return ( - + { )} - + ); };