Dateien nach "frontend/src/tools" hochladen

This commit is contained in:
2026-05-27 08:37:02 +02:00
parent a08d4adb4f
commit fb6b25f3ed

View File

@@ -166,8 +166,10 @@ export default function Dateien({ toast, mobile }) {
const sq = search.toLowerCase();
const currentFolders = tab==='own' ? folders.own : folders.shared;
const currentFiles = tab==='own' ? data.own : data.shared;
const filtFolders = sq ? currentFolders.filter(f=>f.name.toLowerCase().includes(sq)) : currentFolders;
const filtFiles = sq ? currentFiles.filter(f=>f.originalname.toLowerCase().includes(sq)) : currentFiles;
const currentFolders2 = tab==='sharedByMe' ? (folders.sharedByMe||[]) : currentFolders;
const currentFiles2 = tab==='sharedByMe' ? (data.sharedByMe||[]) : currentFiles;
const filtFolders = sq ? currentFolders2.filter(f=>f.name.toLowerCase().includes(sq)) : currentFolders2;
const filtFiles = sq ? currentFiles2.filter(f=>f.originalname.toLowerCase().includes(sq)) : currentFiles2;
const totalSize = data.own.reduce((s,f)=>s+f.size,0);
const inSharedFolder = folderPath.some(p=>p.isShared);
@@ -279,10 +281,13 @@ export default function Dateien({ toast, mobile }) {
<div style={{flex:1,minWidth:0}}>
<div style={{color:'#fff',fontFamily:'monospace',fontSize:13,fontWeight:700}}>{folder.name}</div>
<div style={{color:'rgba(255,255,255,0.45)',fontFamily:'monospace',fontSize:10,marginTop:2}}>
{folder.owner ? `von ${folder.owner} · ` : ''}
{folder.subCount>0?`${folder.subCount} Ordner · `:''}
{folder.fileCount>0?`${folder.fileCount} Datei${folder.fileCount!==1?'en':''} · `:''}
{folder.totalSize>0?fmtSize(folder.totalSize):'leer'}
{[
folder.owner ? `von ${folder.owner}` : null,
folder.subCount>0 ? `${folder.subCount} Ordner` : null,
folder.fileCount>0 ? `${folder.fileCount} Datei${folder.fileCount!==1?'en':''}` : null,
folder.fileCount>0 && folder.totalSize>0 ? fmtSize(folder.totalSize) : null,
(folder.subCount===0 && folder.fileCount===0) ? 'leer' : null,
].filter(Boolean).join(' · ')}
</div>
</div>
{!folder.owner && (