diff --git a/src/Api.ts b/src/Api.ts index 2742398..19d0da2 100644 --- a/src/Api.ts +++ b/src/Api.ts @@ -159,6 +159,16 @@ class Api { }).then(Api.handleResponse); } + public getTorrentPieceStates(hash: string) { + const params = { + hash, + }; + + return this.axios.get('/torrents/pieceStates', { + params, + }).then(Api.handleResponse); + } + public getTorrentFiles(hash: string) { const params = { hash, diff --git a/src/components/dialogs/TorrentInfo.vue b/src/components/dialogs/TorrentInfo.vue index 7e94ca8..88218ec 100644 --- a/src/components/dialogs/TorrentInfo.vue +++ b/src/components/dialogs/TorrentInfo.vue @@ -1,5 +1,10 @@ @@ -177,5 +237,18 @@ export default Vue.extend({ overflow: hidden; white-space: nowrap; } + + .progress { + margin: 0.5em; + display: flex; + + .progress-inner { + margin: 0 1em; + align-self: center; + height: 16px; + flex-grow: 1; + border: 1px inset; + } + } }