Various bugfixes.
This commit is contained in:
		
							parent
							
								
									e9d3b44e97
								
							
						
					
					
						commit
						b95efca29d
					
				@ -10,9 +10,9 @@ class FeeApi {
 | 
			
		||||
    const pBlocks = projectedBlocks.getMempoolBlocks();
 | 
			
		||||
    if (!pBlocks.length) {
 | 
			
		||||
      return {
 | 
			
		||||
        'fastestFee': 0,
 | 
			
		||||
        'halfHourFee': 0,
 | 
			
		||||
        'hourFee': 0,
 | 
			
		||||
        'fastestFee': this.defaultFee,
 | 
			
		||||
        'halfHourFee': this.defaultFee,
 | 
			
		||||
        'hourFee': this.defaultFee,
 | 
			
		||||
      };
 | 
			
		||||
    }
 | 
			
		||||
    let firstMedianFee = Math.ceil(pBlocks[0].medianFee);
 | 
			
		||||
 | 
			
		||||
@ -23,7 +23,7 @@ export class AboutComponent implements OnInit {
 | 
			
		||||
 | 
			
		||||
  ngOnInit() {
 | 
			
		||||
    this.gitCommit$ = this.stateService.gitCommit$;
 | 
			
		||||
    this.seoService.setTitle('Contributors');
 | 
			
		||||
    this.seoService.setTitle('About');
 | 
			
		||||
    this.websocketService.want(['blocks']);
 | 
			
		||||
    if (this.stateService.network === 'bisq') {
 | 
			
		||||
      this.active = 2;
 | 
			
		||||
 | 
			
		||||
@ -2,7 +2,7 @@
 | 
			
		||||
  <span>{{ conversions.USD * (satoshis / 100000000) | currency:'USD':'symbol':'1.2-2' }}</span>
 | 
			
		||||
</ng-container>
 | 
			
		||||
<ng-template #viewFiatVin>
 | 
			
		||||
  <ng-template [ngIf]="network === 'liquid' && satoshis === undefined" [ngIfElse]="default">
 | 
			
		||||
  <ng-template [ngIf]="network === 'liquid' && (satoshis === undefined || satoshis === null)" [ngIfElse]="default">
 | 
			
		||||
    Confidential
 | 
			
		||||
  </ng-template>
 | 
			
		||||
  <ng-template #default>
 | 
			
		||||
 | 
			
		||||
@ -57,7 +57,7 @@
 | 
			
		||||
              </tr>
 | 
			
		||||
              <tr *ngIf="!isNativeAsset">
 | 
			
		||||
                <td>Circulating amount</td>
 | 
			
		||||
                <td>{{ (asset.chain_stats.issued_amount - asset.chain_stats.burned_amount) | number: '1.0-' + assetContract[3] }} {{ assetContract[1] }}</td>
 | 
			
		||||
                <td>{{ (asset.chain_stats.issued_amount - asset.chain_stats.burned_amount) / 100000000 | number: '1.0-' + assetContract[3] }} {{ assetContract[1] }}</td>
 | 
			
		||||
              </tr>
 | 
			
		||||
              <tr *ngIf="isNativeAsset">
 | 
			
		||||
                <td>Circulating amount</td>
 | 
			
		||||
 | 
			
		||||
@ -1,7 +1,7 @@
 | 
			
		||||
import { Component, OnInit, ChangeDetectionStrategy } from '@angular/core';
 | 
			
		||||
import { StateService } from 'src/app/services/state.service';
 | 
			
		||||
import { map, filter } from 'rxjs/operators';
 | 
			
		||||
import { Observable } from 'rxjs';
 | 
			
		||||
import { merge, Observable } from 'rxjs';
 | 
			
		||||
 | 
			
		||||
interface FeeEstimations {
 | 
			
		||||
  fastestFee: number;
 | 
			
		||||
@ -29,8 +29,14 @@ export class FeesBoxComponent implements OnInit {
 | 
			
		||||
    this.isLoadingWebSocket$ = this.stateService.isLoadingWebSocket$;
 | 
			
		||||
    this.feeEstimations$ = this.stateService.mempoolBlocks$
 | 
			
		||||
      .pipe(
 | 
			
		||||
        filter((blocks) => !!blocks.length),
 | 
			
		||||
        map((pBlocks) => {
 | 
			
		||||
          if (!pBlocks.length) {
 | 
			
		||||
            return {
 | 
			
		||||
              'fastestFee': defaultFee,
 | 
			
		||||
              'halfHourFee': defaultFee,
 | 
			
		||||
              'hourFee': defaultFee,
 | 
			
		||||
            };
 | 
			
		||||
          }
 | 
			
		||||
          let firstMedianFee = Math.ceil(pBlocks[0].medianFee);
 | 
			
		||||
 | 
			
		||||
          if (pBlocks.length === 1 && pBlocks[0].blockVSize <= 500000) {
 | 
			
		||||
 | 
			
		||||
@ -34,7 +34,7 @@ export class LatestBlocksComponent implements OnInit, OnDestroy {
 | 
			
		||||
  ) { }
 | 
			
		||||
 | 
			
		||||
  ngOnInit() {
 | 
			
		||||
    this.seoService.resetTitle();
 | 
			
		||||
    this.seoService.setTitle('Blocks');
 | 
			
		||||
    this.websocketService.want(['blocks']);
 | 
			
		||||
 | 
			
		||||
    this.network$ = merge(of(''), this.stateService.networkChanged$);
 | 
			
		||||
 | 
			
		||||
@ -111,15 +111,15 @@
 | 
			
		||||
          <table class="table table-borderless text-left">
 | 
			
		||||
            <thead>
 | 
			
		||||
              <th style="width: 20%;">TXID</th>
 | 
			
		||||
              <th style="width: 35%;" class="text-right d-none d-lg-table-cell">Amount (BTC)</th>
 | 
			
		||||
              <th style="width: 20%;" class="text-right d-none d-lg-table-cell">USD</th>
 | 
			
		||||
              <th style="width: 35%;" class="text-right d-none d-lg-table-cell">Amount</th>
 | 
			
		||||
              <th *ngIf="(network$ | async) !== 'liquid'" style="width: 20%;" class="text-right d-none d-lg-table-cell">USD</th>
 | 
			
		||||
              <th style="width: 25%;" class="text-right">Fee</th>
 | 
			
		||||
            </thead>
 | 
			
		||||
            <tbody>
 | 
			
		||||
              <tr *ngFor="let transaction of transactions$ | async; let i = index;">
 | 
			
		||||
                <td><a [routerLink]="['/tx' | relativeUrl, transaction.txid]">{{ transaction.txid | shortenString : 10 }}</a></td>
 | 
			
		||||
                <td class="text-right d-none d-lg-table-cell"><app-amount [satoshis]="transaction.value" digitsInfo="1.8-8" [noFiat]="true"></app-amount></td>
 | 
			
		||||
                <td class="text-right d-none d-lg-table-cell"><app-fiat [value]="transaction.value" digitsInfo="1.0-0"></app-fiat></td>
 | 
			
		||||
                <td *ngIf="(network$ | async) !== 'liquid'" class="text-right d-none d-lg-table-cell"><app-fiat [value]="transaction.value" digitsInfo="1.0-0"></app-fiat></td>
 | 
			
		||||
                <td class="text-right">{{ transaction.fee / (transaction.weight / 4) | number : '1.1-1' }} sat/vB</td>
 | 
			
		||||
              </tr>
 | 
			
		||||
            </tbody>
 | 
			
		||||
 | 
			
		||||
@ -9,6 +9,7 @@ import { StateService } from '../services/state.service';
 | 
			
		||||
import * as Chartist from 'chartist';
 | 
			
		||||
import { formatDate } from '@angular/common';
 | 
			
		||||
import { WebsocketService } from '../services/websocket.service';
 | 
			
		||||
import { SeoService } from '../services/seo.service';
 | 
			
		||||
 | 
			
		||||
interface MempoolBlocksData {
 | 
			
		||||
  blocks: number;
 | 
			
		||||
@ -58,9 +59,11 @@ export class DashboardComponent implements OnInit {
 | 
			
		||||
    private stateService: StateService,
 | 
			
		||||
    private apiService: ApiService,
 | 
			
		||||
    private websocketService: WebsocketService,
 | 
			
		||||
    private seoService: SeoService,
 | 
			
		||||
  ) { }
 | 
			
		||||
 | 
			
		||||
  ngOnInit(): void {
 | 
			
		||||
    this.seoService.resetTitle();
 | 
			
		||||
    this.websocketService.want(['blocks', 'stats', 'mempool-blocks', 'live-2h-chart']);
 | 
			
		||||
    this.network$ = merge(of(''), this.stateService.networkChanged$);
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
@ -110,6 +110,8 @@ export class WebsocketService {
 | 
			
		||||
        }
 | 
			
		||||
 | 
			
		||||
        if (response['git-commit']) {
 | 
			
		||||
          this.stateService.gitCommit$.next(response['git-commit']);
 | 
			
		||||
 | 
			
		||||
          if (!this.latestGitCommit) {
 | 
			
		||||
            this.latestGitCommit = response['git-commit'];
 | 
			
		||||
          } else {
 | 
			
		||||
 | 
			
		||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user