Fix Bug 69108 - Added display of room sizes under names when sorting by size on mobile.

This commit is contained in:
Tatiana Lopaeva 2024-07-10 13:09:47 +03:00
parent 23670078d5
commit 8f82ff451a

View File

@ -253,6 +253,16 @@ const FilesRowContent = ({
return elem;
});
case SortByFieldName.UsedSpace:
if (usedSpace === undefined) return "";
return getSpaceQuotaAsText(
t,
usedSpace,
quotaLimit,
isDefaultRoomsQuotaSet,
);
default:
if (isTrashFolder)
return t("Files:DaysRemaining", {
@ -264,24 +274,7 @@ const FilesRowContent = ({
};
const additionalComponent = () => {
if (
isRooms &&
isStatisticsAvailable &&
showStorageInfo &&
usedSpace !== undefined
) {
let value = t(ROOMS_TYPE_TRANSLATIONS[item.roomType]);
const spaceQuota = getSpaceQuotaAsText(
t,
usedSpace,
quotaLimit,
isDefaultRoomsQuotaSet,
);
if (!isMobile()) value = `${value} | ${spaceQuota}`;
return value;
}
if (isRooms) return t(ROOMS_TYPE_TRANSLATIONS[item.roomType]);
if (!fileExst && !contentLength && !providerKey)
return `${foldersCount} ${t("Translations:Folders")} | ${filesCount} ${t(