Display at least one standalone mempool block.
Upgrade some packages to ng 9.
This commit is contained in:
@@ -30,10 +30,7 @@ export class AssetsComponent implements OnInit {
|
||||
) { }
|
||||
|
||||
ngOnInit() {
|
||||
this.itemsPerPage = Math.round(this.contentSpace / this.fiveItemsPxSize) * 5;
|
||||
if (this.itemsPerPage === 5) {
|
||||
this.itemsPerPage = 10;
|
||||
}
|
||||
this.itemsPerPage = Math.max(Math.round(this.contentSpace / this.fiveItemsPxSize) * 5, 10);
|
||||
|
||||
setTimeout(() => this.getAssets());
|
||||
|
||||
|
||||
@@ -109,7 +109,7 @@ export class MempoolBlocksComponent implements OnInit, OnDestroy {
|
||||
}
|
||||
|
||||
reduceMempoolBlocksToFitScreen(blocks: MempoolBlock[]): MempoolBlock[] {
|
||||
const blocksAmount = Math.max(1, Math.floor(window.innerWidth / 2 / (this.blockWidth + this.blockPadding)));
|
||||
const blocksAmount = Math.max(2, Math.floor(window.innerWidth / 2 / (this.blockWidth + this.blockPadding)));
|
||||
while (blocks.length > blocksAmount) {
|
||||
const block = blocks.pop();
|
||||
const lastBlock = blocks[blocks.length - 1];
|
||||
|
||||
Reference in New Issue
Block a user