89 lines
		
	
	
		
			3.3 KiB
		
	
	
	
		
			HTML
		
	
	
	
	
	
			
		
		
	
	
			89 lines
		
	
	
		
			3.3 KiB
		
	
	
	
		
			HTML
		
	
	
	
	
	
<div class="container-xl" *ngIf="(channel$ | async) as channel">
 | 
						|
  <h5 class="mb-0" style="color: #ffffff66" i18n="lightning.channel">Lightning channel</h5>
 | 
						|
  <div class="title-container">
 | 
						|
    <h1 class="mb-0">{{ channel.short_id }}</h1>
 | 
						|
    <span class="tx-link">
 | 
						|
      <a [routerLink]="['/lightning/channel' | relativeUrl, channel.id]">{{ channel.id }}</a>
 | 
						|
      <app-clipboard [text]="channel.id"></app-clipboard>
 | 
						|
    </span>
 | 
						|
  </div>
 | 
						|
  <div class="badges mb-2">
 | 
						|
    <span class="badge rounded-pill badge-secondary" *ngIf="channel.status === 0">Inactive</span>
 | 
						|
    <span class="badge rounded-pill badge-success" *ngIf="channel.status === 1">Active</span>
 | 
						|
    <span class="badge rounded-pill badge-danger" *ngIf="channel.status === 2">Closed</span>
 | 
						|
    <app-closing-type *ngIf="channel.closing_reason" [type]="channel.closing_reason"></app-closing-type>
 | 
						|
  </div>
 | 
						|
 | 
						|
  <div class="clearfix"></div>
 | 
						|
 | 
						|
  <app-nodes-channels-map *ngIf="!error && (channelGeo$ | async) as channelGeo" [style]="'channelpage'" [channel]="channelGeo"></app-nodes-channels-map>
 | 
						|
 | 
						|
  <div class="box">
 | 
						|
 | 
						|
      <div class="row">
 | 
						|
        <div class="col-md">
 | 
						|
          <table class="table table-borderless table-striped">
 | 
						|
            <tbody>
 | 
						|
              <tr>
 | 
						|
                <td i18n="address.total-sent">Created</td>
 | 
						|
                <td><app-timestamp [dateString]="channel.created"></app-timestamp></td>
 | 
						|
              </tr>
 | 
						|
              <tr>
 | 
						|
                <td i18n="address.total-sent">Last update</td>
 | 
						|
                <td><app-timestamp [dateString]="channel.updated_at"></app-timestamp></td>
 | 
						|
              </tr>
 | 
						|
            </tbody>
 | 
						|
          </table>
 | 
						|
        </div>
 | 
						|
        <div class="w-100 d-block d-md-none"></div>
 | 
						|
        <div class="col-md">
 | 
						|
          <table class="table table-borderless table-striped">
 | 
						|
            <tbody>
 | 
						|
              <tr>
 | 
						|
                <td i18n="address.total-received">Capacity</td>
 | 
						|
                <td><app-sats [satoshis]="channel.capacity"></app-sats><app-fiat [value]="channel.capacity" digitsInfo="1.0-0"></app-fiat></td>
 | 
						|
              </tr>
 | 
						|
            </tbody>
 | 
						|
          </table>
 | 
						|
        </div>
 | 
						|
      </div>
 | 
						|
 | 
						|
    </div>
 | 
						|
 | 
						|
    <br>
 | 
						|
 | 
						|
    <div class="row row-cols-1 row-cols-md-2">
 | 
						|
      <div class="col">
 | 
						|
        <app-channel-box [channel]="channel.node_left"></app-channel-box>
 | 
						|
      </div>
 | 
						|
      <div class="col">
 | 
						|
        <app-channel-box [channel]="channel.node_right"></app-channel-box>
 | 
						|
      </div>
 | 
						|
    </div>
 | 
						|
    
 | 
						|
    <br>
 | 
						|
 | 
						|
    <ng-container *ngIf="transactions$ | async as transactions">
 | 
						|
      <ng-template [ngIf]="transactions[0]">
 | 
						|
        <h3>Opening transaction</h3>
 | 
						|
        <app-transactions-list [transactions]="[transactions[0]]" [showConfirmations]="true" [rowLimit]="5"></app-transactions-list>
 | 
						|
      </ng-template>
 | 
						|
      <ng-template [ngIf]="transactions[1]">
 | 
						|
        <div class="closing-header">
 | 
						|
          <h3 style="margin: 0;">Closing transaction</h3>  <app-closing-type [type]="channel.closing_reason"></app-closing-type>
 | 
						|
        </div>
 | 
						|
        <app-transactions-list [transactions]="[transactions[1]]" [showConfirmations]="true" [rowLimit]="5"></app-transactions-list>
 | 
						|
      </ng-template>
 | 
						|
    </ng-container>
 | 
						|
 | 
						|
</div>
 | 
						|
 | 
						|
<br>
 | 
						|
 | 
						|
<ng-template [ngIf]="error">
 | 
						|
  <div class="text-center">
 | 
						|
    <span i18n="error.general-loading-data">Error loading data.</span>
 | 
						|
    <br><br>
 | 
						|
    <i>{{ error.status }}: {{ error.error }}</i>
 | 
						|
  </div>
 | 
						|
</ng-template> |