setDimensions(contentRect.bounds)}>
- {({ measureRef }) => (
-
-
-
- Hash {cache.Hash}
-
- Capacity {humanizeSize(cache.Capacity)}
-
- Filled {humanizeSize(cache.Filled)}
-
- Torrent size {' '}
- {cache.Torrent && cache.Torrent.torrent_size && humanizeSize(cache.Torrent.torrent_size)}
-
- Pieces length {humanizeSize(cache.PiecesLength)}
-
- Pieces count {cache.PiecesCount}
-
- Peers: {getPeerString(cache.Torrent)}
-
- Download speed {' '}
- {cache.Torrent && cache.Torrent.download_speed ? `${humanizeSize(cache.Torrent.download_speed)}/sec` : ''}
-
- Upload speed {' '}
- {cache.Torrent && cache.Torrent.upload_speed ? `${humanizeSize(cache.Torrent.upload_speed)}/sec` : ''}
-
- Status {cache.Torrent && cache.Torrent.stat_string && cache.Torrent.stat_string}
-
-
-
-
-
- {isLoading ? (
- 'loading'
- ) : (
-
-
- {cacheMap.map(({ id, percentage, isComplete, inProgress, isActive, isReaderRange }) => {
- const currentRow = Math.floor((isShortView ? id - activeId : id) / piecesInOneRow)
-
- // -------- related only for short view -------
- if (isActive) activeId = id
- const shouldBeRendered =
- isActive || (id - activeId <= amountOfBlocksToRenderInShortView && id - activeId >= 0)
- // --------------------------------------------
-
- return isShortView ? (
- shouldBeRendered && (
-
- )
- ) : (
-
- )
- })}
-
-
- )}
-
-
- )}
-
- )
-}
-
-/*
-{
- "Hash": "41e36c8de915d80db83fc134bee4e7e2d292657e",
- "Capacity": 209715200,
- "Filled": 2914808,
- "PiecesLength": 4194304,
- "PiecesCount": 2065,
- "DownloadSpeed": 32770.860273455524,
- "Pieces": {
- "2064": {
- "Id": 2064,
- "Length": 2914808,
- "Size": 162296,
- "Completed": false
- }
- }
-}
- */
diff --git a/web/src/components/DialogTorrentDetailsContent/index.jsx b/web/src/components/DialogTorrentDetailsContent/index.jsx
index fc47754..93bb969 100644
--- a/web/src/components/DialogTorrentDetailsContent/index.jsx
+++ b/web/src/components/DialogTorrentDetailsContent/index.jsx
@@ -9,6 +9,9 @@ import {
ArrowUpward as ArrowUpwardIcon,
SwapVerticalCircle as SwapVerticalCircleIcon,
ViewAgenda as ViewAgendaIcon,
+ Widgets as WidgetsIcon,
+ PhotoSizeSelectSmall as PhotoSizeSelectSmallIcon,
+ Build as BuildIcon,
} from '@material-ui/icons'
import axios from 'axios'
import { playlistTorrHost, streamHost, torrentsHost, viewedHost } from 'utils/Hosts'
@@ -117,9 +120,63 @@ export default function DialogTorrentDetailsContent({ closeDialog, torrent }) {
'loading'
) : isDetailedCacheView ? (