mirror of
https://github.com/strapi/strapi.git
synced 2025-11-01 10:23:34 +00:00
tooltip for every table headers + fix asset count displayed
This commit is contained in:
parent
bd3f68f70f
commit
98a39535e9
@ -80,8 +80,8 @@ export const TableList = ({
|
||||
}
|
||||
key={key}
|
||||
>
|
||||
{isSortable ? (
|
||||
<Tooltip label={sortLabel}>
|
||||
<Tooltip label={isSortable ? sortLabel : tableHeaderLabel}>
|
||||
{isSortable ? (
|
||||
<Typography
|
||||
onClick={() => handleClickSort(isSorted, name)}
|
||||
as={isSorted ? 'span' : 'button'}
|
||||
@ -91,12 +91,12 @@ export const TableList = ({
|
||||
>
|
||||
{tableHeaderLabel}
|
||||
</Typography>
|
||||
</Tooltip>
|
||||
) : (
|
||||
<Typography textColor="neutral600" variant="sigma">
|
||||
{tableHeaderLabel}
|
||||
</Typography>
|
||||
)}
|
||||
) : (
|
||||
<Typography textColor="neutral600" variant="sigma">
|
||||
{tableHeaderLabel}
|
||||
</Typography>
|
||||
)}
|
||||
</Tooltip>
|
||||
</Th>
|
||||
);
|
||||
})}
|
||||
|
||||
@ -136,6 +136,7 @@ export const MediaLibrary = () => {
|
||||
assetsData?.results?.map((asset) => ({ ...asset, type: 'asset', isSelectable: canUpdate })) ||
|
||||
[];
|
||||
const assetCount = assets?.length ?? 0;
|
||||
const totalAssetCount = assetsData?.pagination?.total;
|
||||
|
||||
const isLoading = isCurrentFolderLoading || foldersLoading || permissionsLoading || assetsLoading;
|
||||
const [showUploadAssetDialog, setShowUploadAssetDialog] = useState(false);
|
||||
@ -458,7 +459,7 @@ export const MediaLibrary = () => {
|
||||
id: getTrad('list.assets.title'),
|
||||
defaultMessage: 'Assets ({count})',
|
||||
},
|
||||
{ count: assetCount }
|
||||
{ count: totalAssetCount }
|
||||
)) ||
|
||||
''
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user