diff --git a/frontend/src/app/lightning/node/node.component.scss b/frontend/src/app/lightning/node/node.component.scss
index 3803ce2fb..fe9737b85 100644
--- a/frontend/src/app/lightning/node/node.component.scss
+++ b/frontend/src/app/lightning/node/node.component.scss
@@ -72,3 +72,18 @@ app-fiat {
height: 28px !important;
};
}
+
+.details tbody {
+ font-size: 12px;
+
+ .tlv-type {
+ color: #ffffff66;
+ }
+
+ .tlv-payload {
+ width: 100%;
+ word-break: break-all;
+ white-space: normal;
+ font-family: "Courier New", Courier, monospace;
+ }
+}
diff --git a/frontend/src/app/lightning/node/node.component.ts b/frontend/src/app/lightning/node/node.component.ts
index e2a8123ac..161a53e37 100644
--- a/frontend/src/app/lightning/node/node.component.ts
+++ b/frontend/src/app/lightning/node/node.component.ts
@@ -1,7 +1,7 @@
import { ChangeDetectionStrategy, Component, OnInit } from '@angular/core';
import { ActivatedRoute, ParamMap } from '@angular/router';
import { Observable } from 'rxjs';
-import { catchError, map, switchMap } from 'rxjs/operators';
+import { catchError, map, switchMap, tap } from 'rxjs/operators';
import { SeoService } from '../../services/seo.service';
import { LightningApiService } from '../lightning-api.service';
import { GeolocationData } from '../../shared/components/geolocation/geolocation.component';
@@ -24,6 +24,8 @@ export class NodeComponent implements OnInit {
channelListLoading = false;
clearnetSocketCount = 0;
torSocketCount = 0;
+ hasDetails = false;
+ showDetails = false;
constructor(
private lightningApiService: LightningApiService,
@@ -79,6 +81,9 @@ export class NodeComponent implements OnInit {
return node;
}),
+ tap((node) => {
+ this.hasDetails = Object.keys(node.custom_records).length > 0;
+ }),
catchError(err => {
this.error = err;
return [{
@@ -89,6 +94,10 @@ export class NodeComponent implements OnInit {
);
}
+ toggleShowDetails(): void {
+ this.showDetails = !this.showDetails;
+ }
+
changeSocket(index: number) {
this.selectedSocketIndex = index;
}