- Balance Score |
-
+ | Balance Score |
+
{{channel.balancedness || 0 | number}}
@@ -69,7 +100,7 @@
-
+
Update Fee Policy
diff --git a/src/app/cln/peers-channels/channels/channels-tables/channel-open-table/channel-open-table.component.scss b/src/app/cln/peers-channels/channels/channels-tables/channel-open-table/channel-open-table.component.scss
index fa046b31..23346df9 100644
--- a/src/app/cln/peers-channels/channels/channels-tables/channel-open-table/channel-open-table.component.scss
+++ b/src/app/cln/peers-channels/channels/channels-tables/channel-open-table/channel-open-table.component.scss
@@ -1,16 +1,12 @@
@import "../../../../../shared/theme/styles/mixins.scss";
-.mat-column-short_channel_id {
- flex: 0 0 15%;
- width: 15%;
- & .ellipsis-parent {
- display: flex;
- }
+.mat-column-private {
+ width: 2rem;
}
-.mat-column-alias {
- flex: 0 0 20%;
- width: 20%;
+.mat-column-short_channel_id, .mat-column-alias, .mat-column-id, .mat-column-channel_id, .mat-column-funding_txid {
+ flex: 0 0 15%;
+ width: 15%;
& .ellipsis-parent {
display: flex;
}
@@ -35,10 +31,4 @@
.mat-column-actions {
min-height: 4.8rem;
- & .bordered-box.table-actions-select {
- flex: 0 0 100%;
- @include for_screensize(phone) {
- flex: 0 0 80%;
- }
- }
}
diff --git a/src/app/cln/peers-channels/channels/channels-tables/channel-open-table/channel-open-table.component.ts b/src/app/cln/peers-channels/channels/channels-tables/channel-open-table/channel-open-table.component.ts
index 72b99fb2..d2a2f2ea 100644
--- a/src/app/cln/peers-channels/channels/channels-tables/channel-open-table/channel-open-table.component.ts
+++ b/src/app/cln/peers-channels/channels/channels-tables/channel-open-table/channel-open-table.component.ts
@@ -9,7 +9,7 @@ import { MatPaginator, MatPaginatorIntl } from '@angular/material/paginator';
import { MatSort } from '@angular/material/sort';
import { MatTableDataSource } from '@angular/material/table';
import { Channel, GetInfo, ChannelEdge, Balance } from '../../../../../shared/models/clnModels';
-import { PAGE_SIZE, PAGE_SIZE_OPTIONS, getPaginatorLabel, AlertTypeEnum, DataTypeEnum, ScreenSizeEnum, FEE_RATE_TYPES, APICallStatusEnum, UI_MESSAGES } from '../../../../../shared/services/consts-enums-functions';
+import { PAGE_SIZE, PAGE_SIZE_OPTIONS, getPaginatorLabel, AlertTypeEnum, DataTypeEnum, ScreenSizeEnum, FEE_RATE_TYPES, APICallStatusEnum, UI_MESSAGES, CLN_DEFAULT_PAGE_SETTINGS, SortOrderEnum } from '../../../../../shared/services/consts-enums-functions';
import { ApiCallStatusPayload } from '../../../../../shared/models/apiCallsPayload';
import { LoggerService } from '../../../../../shared/services/logger.service';
import { CommonService } from '../../../../../shared/services/common.service';
@@ -21,7 +21,8 @@ import { RTLEffects } from '../../../../../store/rtl.effects';
import { openAlert, openConfirmation } from '../../../../../store/rtl.actions';
import { RTLState } from '../../../../../store/rtl.state';
import { channelLookup, closeChannel, updateChannel } from '../../../../store/cln.actions';
-import { channels, nodeInfoAndBalanceAndNumPeers } from '../../../../store/cln.selector';
+import { channels, clnPageSettings, nodeInfoAndBalanceAndNumPeers } from '../../../../store/cln.selector';
+import { PageSettingsCLN, TableSetting } from '../../../../../shared/models/pageSettings';
@Component({
selector: 'rtl-cln-channel-open-table',
@@ -37,6 +38,8 @@ export class CLNChannelOpenTableComponent implements OnInit, AfterViewInit, OnDe
@ViewChild(MatPaginator, { static: false }) paginator: MatPaginator | undefined;
public faEye = faEye;
public faEyeSlash = faEyeSlash;
+ public PAGE_ID = 'peers/channels';
+ public tableSetting: TableSetting = { tableId: 'open_channels', recordsPerPage: PAGE_SIZE, sortBy: 'alias', sortOrder: SortOrderEnum.DESCENDING };
public totalBalance = 0;
public displayedColumns: any[] = [];
public channelsData: Channel[] = [];
@@ -53,19 +56,10 @@ export class CLNChannelOpenTableComponent implements OnInit, AfterViewInit, OnDe
public errorMessage = '';
public apiCallStatus: ApiCallStatusPayload | null = null;
public apiCallStatusEnum = APICallStatusEnum;
- private unSubs: Array> = [new Subject(), new Subject(), new Subject(), new Subject(), new Subject(), new Subject()];
+ private unSubs: Array> = [new Subject(), new Subject(), new Subject(), new Subject(), new Subject(), new Subject(), new Subject(), new Subject(), new Subject()];
constructor(private logger: LoggerService, private store: Store, private rtlEffects: RTLEffects, private clnEffects: CLNEffects, private commonService: CommonService, private router: Router) {
this.screenSize = this.commonService.getScreenSize();
- if (this.screenSize === ScreenSizeEnum.XS) {
- this.displayedColumns = ['alias', 'msatoshi_to_us', 'msatoshi_to_them', 'actions'];
- } else if (this.screenSize === ScreenSizeEnum.SM) {
- this.displayedColumns = ['short_channel_id', 'alias', 'msatoshi_to_us', 'msatoshi_to_them', 'actions'];
- } else if (this.screenSize === ScreenSizeEnum.MD) {
- this.displayedColumns = ['short_channel_id', 'alias', 'msatoshi_to_us', 'msatoshi_to_them', 'actions'];
- } else {
- this.displayedColumns = ['short_channel_id', 'alias', 'msatoshi_to_us', 'msatoshi_to_them', 'balancedness', 'actions'];
- }
this.selFilter = this.router?.getCurrentNavigation()?.extras?.state?.filter ? this.router?.getCurrentNavigation()?.extras?.state?.filter : '';
}
@@ -77,7 +71,25 @@ export class CLNChannelOpenTableComponent implements OnInit, AfterViewInit, OnDe
this.totalBalance = infoBalNumpeersSelector.balance.totalBalance || 0;
this.logger.info(infoBalNumpeersSelector);
});
- this.store.select(channels).pipe(takeUntil(this.unSubs[1])).
+ this.store.select(clnPageSettings).pipe(takeUntil(this.unSubs[1])).
+ subscribe((settings: { pageSettings: PageSettingsCLN[], apiCallStatus: ApiCallStatusPayload }) => {
+ this.errorMessage = '';
+ this.apiCallStatus = settings.apiCallStatus;
+ if (this.apiCallStatus.status === APICallStatusEnum.ERROR) {
+ this.errorMessage = this.apiCallStatus.message || '';
+ }
+ this.tableSetting = settings.pageSettings.find((page) => page.pageId === this.PAGE_ID)?.tables.find((table) => table.tableId === this.tableSetting.tableId) || CLN_DEFAULT_PAGE_SETTINGS.find((page) => page.pageId === this.PAGE_ID)?.tables.find((table) => table.tableId === this.tableSetting.tableId)!;
+ if (this.screenSize === ScreenSizeEnum.XS || this.screenSize === ScreenSizeEnum.SM) {
+ this.displayedColumns = JSON.parse(JSON.stringify(this.tableSetting.columnSelectionSM));
+ } else {
+ this.displayedColumns = JSON.parse(JSON.stringify(this.tableSetting.columnSelection));
+ }
+ this.displayedColumns.unshift('private');
+ this.displayedColumns.push('actions');
+ this.pageSize = this.tableSetting.recordsPerPage ? +this.tableSetting.recordsPerPage : PAGE_SIZE;
+ this.logger.info(this.displayedColumns);
+ });
+ this.store.select(channels).pipe(takeUntil(this.unSubs[2])).
subscribe((channelsSeletor: { activeChannels: Channel[], pendingChannels: Channel[], inactiveChannels: Channel[], apiCallStatus: ApiCallStatusPayload }) => {
this.errorMessage = '';
this.apiCallStatus = channelsSeletor.apiCallStatus;
@@ -154,7 +166,7 @@ export class CLNChannelOpenTableComponent implements OnInit, AfterViewInit, OnDe
}
}
}));
- this.rtlEffects.closeConfirm.pipe(takeUntil(this.unSubs[1])).subscribe((confirmRes) => {
+ this.rtlEffects.closeConfirm.pipe(takeUntil(this.unSubs[3])).subscribe((confirmRes) => {
if (confirmRes) {
const base_fee = confirmRes[0].inputValue;
const fee_rate = confirmRes[1].inputValue;
@@ -196,7 +208,7 @@ export class CLNChannelOpenTableComponent implements OnInit, AfterViewInit, OnDe
}, 0);
});
this.rtlEffects.closeConfirm.
- pipe(takeUntil(this.unSubs[2])).
+ pipe(takeUntil(this.unSubs[4])).
subscribe((confirmRes) => {
if (confirmRes) {
const base_fee = confirmRes[0].inputValue;
@@ -225,7 +237,7 @@ export class CLNChannelOpenTableComponent implements OnInit, AfterViewInit, OnDe
}
}));
this.rtlEffects.closeConfirm.
- pipe(takeUntil(this.unSubs[3])).
+ pipe(takeUntil(this.unSubs[5])).
subscribe((confirmRes) => {
if (confirmRes) {
this.store.dispatch(closeChannel({ payload: { id: channelToClose.id || '', channelId: channelToClose.channel_id || '', force: false } }));
@@ -250,8 +262,11 @@ export class CLNChannelOpenTableComponent implements OnInit, AfterViewInit, OnDe
}
loadChannelsTable(mychannels) {
- mychannels.sort((a, b) => ((a.active === b.active) ? 0 : ((b.active) ? 1 : -1)));
+ // mychannels.sort((a, b) => ((a.active === b.active) ? 0 : ((b.active) ? 1 : -1)));
this.channels = new MatTableDataSource([...mychannels]);
+ this.channels.sort = this.sort;
+ this.channels.sortingDataAccessor = (data: any, sortHeaderId: string) => ((data[sortHeaderId] && isNaN(data[sortHeaderId])) ? data[sortHeaderId].toLocaleLowerCase() : data[sortHeaderId] ? +data[sortHeaderId] : null);
+ this.channels.sort?.sort({ id: this.tableSetting.sortBy, start: this.tableSetting.sortOrder, disableClear: true });
this.channels.filterPredicate = (channel: Channel, fltr: string) => {
const newChannel = ((channel.connected) ? 'connected' : 'disconnected') + (channel.channel_id ? channel.channel_id.toLowerCase() : '') +
(channel.short_channel_id ? channel.short_channel_id.toLowerCase() : '') + (channel.id ? channel.id.toLowerCase() : '') + (channel.alias ? channel.alias.toLowerCase() : '') +
@@ -261,8 +276,6 @@ export class CLNChannelOpenTableComponent implements OnInit, AfterViewInit, OnDe
(channel.our_channel_reserve_satoshis ? channel.our_channel_reserve_satoshis : '') + (channel.spendable_msatoshi ? channel.spendable_msatoshi : '');
return newChannel.includes(fltr);
};
- this.channels.sort = this.sort;
- this.channels.sortingDataAccessor = (data: any, sortHeaderId: string) => ((data[sortHeaderId] && isNaN(data[sortHeaderId])) ? data[sortHeaderId].toLocaleLowerCase() : data[sortHeaderId] ? +data[sortHeaderId] : null);
this.channels.paginator = this.paginator;
this.applyFilter();
this.logger.info(this.channels);
diff --git a/src/app/cln/peers-channels/channels/channels-tables/channel-pending-table/channel-pending-table.component.html b/src/app/cln/peers-channels/channels/channels-tables/channel-pending-table/channel-pending-table.component.html
index 2f4ff02e..51012cf0 100644
--- a/src/app/cln/peers-channels/channels/channels-tables/channel-pending-table/channel-pending-table.component.html
+++ b/src/app/cln/peers-channels/channels/channels-tables/channel-pending-table/channel-pending-table.component.html
@@ -1,4 +1,4 @@
-
+
@@ -8,52 +8,94 @@
-
- Short Channel ID |
- {{channel?.short_channel_id}} |
+
+ |
+
+
+
+ |
- Alias |
- {{channel?.alias}} |
+ Alias |
+
+
+ {{channel?.alias}}
+
+ |
-
- Connected |
- {{(channel?.connected) ? 'Connected' : 'Disconnected'}} |
+
+ Id |
+
+
+ {{channel?.id}}
+
+ |
-
- Private |
- {{(channel?.private ? 'Private' : 'Public')}} |
+
+ Channel Id |
+
+
+ {{channel?.channel_id}}
+
+ |
+
+
+ Funding Transaction Id |
+
+
+ {{channel?.funding_txid}}
+
+ |
+
+
+ Connected |
+ {{(channel?.connected) ? 'Connected' : 'Disconnected'}} |
State |
- {{CLNChannelPendingState[channel?.state]}} |
+ {{CLNChannelPendingState[channel?.state]}} |
-
- mSatoshi To Us |
-
- {{channel?.msatoshi_to_us | number}} |
+
+ Local Reserve (Sats) |
+
+ {{channel?.our_channel_reserve_satoshis | number:'1.0-0'}} |
+
+
+ Remote Reserve (Sats) |
+
+ {{channel?.their_channel_reserve_satoshis | number:'1.0-0'}} |
- Total (Sats) |
-
- {{channel?.msatoshi_total/1000 | number}} |
+ Total (Sats) |
+
+ {{channel?.msatoshi_total/1000 | number:channel?.msatoshi_to_us < 1000 ? '1.0-4' : '1.0-0'}} |
- Spendable Satoshi |
-
- {{channel?.spendable_msatoshi | number}} |
+ Spendable (Sats) |
+
+ {{channel?.spendable_msatoshi/1000 | number:channel?.msatoshi_to_us < 1000 ? '1.0-4' : '1.0-0'}} |
+
+
+ Local Balance (Sats) |
+
+ {{channel?.msatoshi_to_us/1000 | number:channel?.msatoshi_to_us < 1000 ? '1.0-4' : '1.0-0'}} |
+
+
+ Remote Balance (Sats) |
+
+ {{channel?.msatoshi_to_them/1000 | number:channel?.msatoshi_to_them < 1000 ? '1.0-4' : '1.0-0'}} |
-
-
+
+
Download CSV
|
-
-
+
+
View Info
diff --git a/src/app/cln/peers-channels/channels/channels-tables/channel-pending-table/channel-pending-table.component.scss b/src/app/cln/peers-channels/channels/channels-tables/channel-pending-table/channel-pending-table.component.scss
index e04787fd..aa96d827 100644
--- a/src/app/cln/peers-channels/channels/channels-tables/channel-pending-table/channel-pending-table.component.scss
+++ b/src/app/cln/peers-channels/channels/channels-tables/channel-pending-table/channel-pending-table.component.scss
@@ -1,12 +1,28 @@
@import "../../../../../shared/theme/styles/mixins.scss";
-.mat-column-actions {
- min-height: 4.8rem;
+.mat-column-private {
+ width: 2rem;
+}
+
+.mat-column-short_channel_id, .mat-column-alias, .mat-column-id, .mat-column-channel_id, .mat-column-funding_txid {
+ flex: 0 0 15%;
+ width: 15%;
+ & .ellipsis-parent {
+ display: flex;
+ }
}
-.mat-column-state {
+.mat-column-state, .mat-column-msatoshi_to_us, .mat-column-msatoshi_to_them {
flex: 1 1 15%;
+ width: 15%;
white-space: nowrap;
- overflow: hidden;
+ overflow: hidden;
text-overflow: ellipsis;
+ @include for_screensize(phone) {
+ white-space: unset;
+ }
+}
+
+.mat-column-actions {
+ min-height: 4.8rem;
}
diff --git a/src/app/cln/peers-channels/channels/channels-tables/channel-pending-table/channel-pending-table.component.ts b/src/app/cln/peers-channels/channels/channels-tables/channel-pending-table/channel-pending-table.component.ts
index b3726580..c142cc2b 100644
--- a/src/app/cln/peers-channels/channels/channels-tables/channel-pending-table/channel-pending-table.component.ts
+++ b/src/app/cln/peers-channels/channels/channels-tables/channel-pending-table/channel-pending-table.component.ts
@@ -5,9 +5,10 @@ import { Store } from '@ngrx/store';
import { MatPaginator, MatPaginatorIntl } from '@angular/material/paginator';
import { MatSort } from '@angular/material/sort';
import { MatTableDataSource } from '@angular/material/table';
+import { faEye, faEyeSlash } from '@fortawesome/free-solid-svg-icons';
import { GetInfo, Channel, Balance } from '../../../../../shared/models/clnModels';
-import { PAGE_SIZE, PAGE_SIZE_OPTIONS, getPaginatorLabel, ScreenSizeEnum, FEE_RATE_TYPES, AlertTypeEnum, APICallStatusEnum, CLNChannelPendingState } from '../../../../../shared/services/consts-enums-functions';
+import { PAGE_SIZE, PAGE_SIZE_OPTIONS, getPaginatorLabel, ScreenSizeEnum, FEE_RATE_TYPES, AlertTypeEnum, APICallStatusEnum, CLNChannelPendingState, SortOrderEnum, CLN_DEFAULT_PAGE_SETTINGS } from '../../../../../shared/services/consts-enums-functions';
import { ApiCallStatusPayload } from '../../../../../shared/models/apiCallsPayload';
import { LoggerService } from '../../../../../shared/services/logger.service';
import { CommonService } from '../../../../../shared/services/common.service';
@@ -18,7 +19,8 @@ import { CLNBumpFeeComponent } from '../../bump-fee-modal/bump-fee.component';
import { openAlert, openConfirmation } from '../../../../../store/rtl.actions';
import { RTLState } from '../../../../../store/rtl.state';
import { closeChannel } from '../../../../store/cln.actions';
-import { channels, nodeInfoAndBalanceAndNumPeers } from '../../../../store/cln.selector';
+import { channels, clnPageSettings, nodeInfoAndBalanceAndNumPeers } from '../../../../store/cln.selector';
+import { PageSettingsCLN, TableSetting } from '../../../../../shared/models/pageSettings';
@Component({
selector: 'rtl-cln-channel-pending-table',
@@ -32,6 +34,10 @@ export class CLNChannelPendingTableComponent implements OnInit, AfterViewInit, O
@ViewChild(MatSort, { static: false }) sort: MatSort | undefined;
@ViewChild(MatPaginator, { static: false }) paginator: MatPaginator | undefined;
+ public faEye = faEye;
+ public faEyeSlash = faEyeSlash;
+ public PAGE_ID = 'peers/channels';
+ public tableSetting: TableSetting = { tableId: 'pending_inactive_channels', recordsPerPage: PAGE_SIZE, sortBy: 'alias', sortOrder: SortOrderEnum.DESCENDING };
public isCompatibleVersion = false;
public totalBalance = 0;
public displayedColumns: any[] = [];
@@ -54,15 +60,6 @@ export class CLNChannelPendingTableComponent implements OnInit, AfterViewInit, O
constructor(private logger: LoggerService, private store: Store, private rtlEffects: RTLEffects, private commonService: CommonService) {
this.screenSize = this.commonService.getScreenSize();
- if (this.screenSize === ScreenSizeEnum.XS) {
- this.displayedColumns = ['alias', 'state', 'actions'];
- } else if (this.screenSize === ScreenSizeEnum.SM) {
- this.displayedColumns = ['alias', 'connected', 'state', 'actions'];
- } else if (this.screenSize === ScreenSizeEnum.MD) {
- this.displayedColumns = ['alias', 'connected', 'state', 'msatoshi_total', 'actions'];
- } else {
- this.displayedColumns = ['alias', 'connected', 'state', 'msatoshi_total', 'actions'];
- }
}
ngOnInit() {
@@ -76,7 +73,25 @@ export class CLNChannelPendingTableComponent implements OnInit, AfterViewInit, O
this.totalBalance = infoBalNumpeersSelector.balance.totalBalance || 0;
this.logger.info(infoBalNumpeersSelector);
});
- this.store.select(channels).pipe(takeUntil(this.unSubs[1])).
+ this.store.select(clnPageSettings).pipe(takeUntil(this.unSubs[1])).
+ subscribe((settings: { pageSettings: PageSettingsCLN[], apiCallStatus: ApiCallStatusPayload }) => {
+ this.errorMessage = '';
+ this.apiCallStatus = settings.apiCallStatus;
+ if (this.apiCallStatus.status === APICallStatusEnum.ERROR) {
+ this.errorMessage = this.apiCallStatus.message || '';
+ }
+ this.tableSetting = settings.pageSettings.find((page) => page.pageId === this.PAGE_ID)?.tables.find((table) => table.tableId === this.tableSetting.tableId) || CLN_DEFAULT_PAGE_SETTINGS.find((page) => page.pageId === this.PAGE_ID)?.tables.find((table) => table.tableId === this.tableSetting.tableId)!;
+ if (this.screenSize === ScreenSizeEnum.XS || this.screenSize === ScreenSizeEnum.SM) {
+ this.displayedColumns = JSON.parse(JSON.stringify(this.tableSetting.columnSelectionSM));
+ } else {
+ this.displayedColumns = JSON.parse(JSON.stringify(this.tableSetting.columnSelection));
+ }
+ this.displayedColumns.unshift('private');
+ this.displayedColumns.push('actions');
+ this.pageSize = this.tableSetting.recordsPerPage ? +this.tableSetting.recordsPerPage : PAGE_SIZE;
+ this.logger.info(this.displayedColumns);
+ });
+ this.store.select(channels).pipe(takeUntil(this.unSubs[2])).
subscribe((channelsSeletor: { activeChannels: Channel[], pendingChannels: Channel[], inactiveChannels: Channel[], apiCallStatus: ApiCallStatusPayload }) => {
this.errorMessage = '';
this.apiCallStatus = channelsSeletor.apiCallStatus;
@@ -138,7 +153,7 @@ export class CLNChannelPendingTableComponent implements OnInit, AfterViewInit, O
}
}));
this.rtlEffects.closeConfirm.
- pipe(takeUntil(this.unSubs[2])).
+ pipe(takeUntil(this.unSubs[3])).
subscribe((confirmRes) => {
if (confirmRes) {
this.store.dispatch(closeChannel({ payload: { id: channelToClose.id!, channelId: channelToClose.channel_id!, force: true } }));
@@ -147,7 +162,7 @@ export class CLNChannelPendingTableComponent implements OnInit, AfterViewInit, O
}
loadChannelsTable(mychannels) {
- mychannels.sort((a, b) => ((a.active === b.active) ? 0 : ((b.active) ? 1 : -1)));
+ // mychannels.sort((a, b) => ((a.active === b.active) ? 0 : ((b.active) ? 1 : -1)));
this.channels = new MatTableDataSource([...mychannels]);
this.channels.filterPredicate = (channel: Channel, fltr: string) => {
const newChannel = ((channel.connected) ? 'connected' : 'disconnected') + (channel.channel_id ? channel.channel_id.toLowerCase() : '') +
@@ -168,6 +183,7 @@ export class CLNChannelPendingTableComponent implements OnInit, AfterViewInit, O
return (data[sortHeaderId] && isNaN(data[sortHeaderId])) ? data[sortHeaderId].toLocaleLowerCase() : data[sortHeaderId] ? +data[sortHeaderId] : null;
}
};
+ this.channels.sort?.sort({ id: this.tableSetting.sortBy, start: this.tableSetting.sortOrder, disableClear: true });
this.channels.paginator = this.paginator;
this.logger.info(this.channels);
}
diff --git a/src/app/cln/peers-channels/peers/peers.component.html b/src/app/cln/peers-channels/peers/peers.component.html
index 54f56163..e1ec6aa8 100644
--- a/src/app/cln/peers-channels/peers/peers.component.html
+++ b/src/app/cln/peers-channels/peers/peers.component.html
@@ -17,11 +17,16 @@
+
+ |
+
+
+
+ |
+
Alias |
-
-
{{peer?.alias}}
|
@@ -33,13 +38,13 @@
Network Address |
-
+ |
{{addr}},
|
-
+
Download CSV
@@ -47,7 +52,7 @@
|
-
+
View Info
diff --git a/src/app/cln/peers-channels/peers/peers.component.scss b/src/app/cln/peers-channels/peers/peers.component.scss
index 680fd8b3..e679095b 100644
--- a/src/app/cln/peers-channels/peers/peers.component.scss
+++ b/src/app/cln/peers-channels/peers/peers.component.scss
@@ -1,3 +1,7 @@
+.mat-column-connected {
+ width: 2rem;
+}
+
.mat-column-alias {
flex: 1 1 20%;
white-space: nowrap;
diff --git a/src/app/cln/peers-channels/peers/peers.component.ts b/src/app/cln/peers-channels/peers/peers.component.ts
index 39577631..e6fcb5fd 100644
--- a/src/app/cln/peers-channels/peers/peers.component.ts
+++ b/src/app/cln/peers-channels/peers/peers.component.ts
@@ -10,7 +10,7 @@ import { MatPaginator, MatPaginatorIntl } from '@angular/material/paginator';
import { MatSort } from '@angular/material/sort';
import { MatTableDataSource } from '@angular/material/table';
import { Peer, GetInfo, Balance } from '../../../shared/models/clnModels';
-import { PAGE_SIZE, PAGE_SIZE_OPTIONS, getPaginatorLabel, AlertTypeEnum, ScreenSizeEnum, APICallStatusEnum, CLNActions } from '../../../shared/services/consts-enums-functions';
+import { PAGE_SIZE, PAGE_SIZE_OPTIONS, getPaginatorLabel, AlertTypeEnum, ScreenSizeEnum, APICallStatusEnum, CLNActions, SortOrderEnum, CLN_DEFAULT_PAGE_SETTINGS } from '../../../shared/services/consts-enums-functions';
import { ApiCallStatusPayload } from '../../../shared/models/apiCallsPayload';
import { LoggerService } from '../../../shared/services/logger.service';
import { CommonService } from '../../../shared/services/common.service';
@@ -21,7 +21,8 @@ import { RTLEffects } from '../../../store/rtl.effects';
import { RTLState } from '../../../store/rtl.state';
import { openAlert, openConfirmation } from '../../../store/rtl.actions';
import { detachPeer } from '../../store/cln.actions';
-import { nodeInfoAndBalance, peers } from '../../store/cln.selector';
+import { clnPageSettings, nodeInfoAndBalance, peers } from '../../store/cln.selector';
+import { PageSettingsCLN, TableSetting } from '../../../shared/models/pageSettings';
@Component({
selector: 'rtl-cln-peers',
@@ -36,6 +37,8 @@ export class CLNPeersComponent implements OnInit, AfterViewInit, OnDestroy {
@ViewChild(MatSort, { static: false }) sort: MatSort | undefined;
@ViewChild(MatPaginator, { static: false }) paginator: MatPaginator | undefined;
public faUsers = faUsers;
+ public PAGE_ID = 'peers/channels';
+ public tableSetting: TableSetting = { tableId: 'peers', recordsPerPage: PAGE_SIZE, sortBy: 'alias', sortOrder: SortOrderEnum.DESCENDING };
public newlyAddedPeer = '';
public displayedColumns: any[] = [];
public peerAddress: string | null = '';
@@ -51,19 +54,10 @@ export class CLNPeersComponent implements OnInit, AfterViewInit, OnDestroy {
public selFilter = '';
public apiCallStatus: ApiCallStatusPayload | null = null;
public apiCallStatusEnum = APICallStatusEnum;
- private unSubs: Array> = [new Subject(), new Subject(), new Subject(), new Subject()];
+ private unSubs: Array> = [new Subject(), new Subject(), new Subject(), new Subject(), new Subject(), new Subject()];
constructor(private logger: LoggerService, private store: Store, private rtlEffects: RTLEffects, private actions: Actions, private commonService: CommonService) {
this.screenSize = this.commonService.getScreenSize();
- if (this.screenSize === ScreenSizeEnum.XS) {
- this.displayedColumns = ['alias', 'actions'];
- } else if (this.screenSize === ScreenSizeEnum.SM) {
- this.displayedColumns = ['alias', 'id', 'netaddr', 'actions'];
- } else if (this.screenSize === ScreenSizeEnum.MD) {
- this.displayedColumns = ['alias', 'id', 'netaddr', 'actions'];
- } else {
- this.displayedColumns = ['alias', 'id', 'netaddr', 'actions'];
- }
}
ngOnInit() {
@@ -72,7 +66,25 @@ export class CLNPeersComponent implements OnInit, AfterViewInit, OnDestroy {
this.information = infoBalSelector.information;
this.availableBalance = infoBalSelector.balance.totalBalance || 0;
});
- this.store.select(peers).pipe(takeUntil(this.unSubs[1])).
+ this.store.select(clnPageSettings).pipe(takeUntil(this.unSubs[1])).
+ subscribe((settings: { pageSettings: PageSettingsCLN[], apiCallStatus: ApiCallStatusPayload }) => {
+ this.errorMessage = '';
+ this.apiCallStatus = settings.apiCallStatus;
+ if (this.apiCallStatus.status === APICallStatusEnum.ERROR) {
+ this.errorMessage = this.apiCallStatus.message || '';
+ }
+ this.tableSetting = settings.pageSettings.find((page) => page.pageId === this.PAGE_ID)?.tables.find((table) => table.tableId === this.tableSetting.tableId) || CLN_DEFAULT_PAGE_SETTINGS.find((page) => page.pageId === this.PAGE_ID)?.tables.find((table) => table.tableId === this.tableSetting.tableId)!;
+ if (this.screenSize === ScreenSizeEnum.XS || this.screenSize === ScreenSizeEnum.SM) {
+ this.displayedColumns = JSON.parse(JSON.stringify(this.tableSetting.columnSelectionSM));
+ } else {
+ this.displayedColumns = JSON.parse(JSON.stringify(this.tableSetting.columnSelection));
+ }
+ this.displayedColumns.unshift('connected');
+ this.displayedColumns.push('actions');
+ this.pageSize = this.tableSetting.recordsPerPage ? +this.tableSetting.recordsPerPage : PAGE_SIZE;
+ this.logger.info(this.displayedColumns);
+ });
+ this.store.select(peers).pipe(takeUntil(this.unSubs[2])).
subscribe((peersSeletor: { peers: Peer[], apiCallStatus: ApiCallStatusPayload }) => {
this.errorMessage = '';
this.apiCallStatus = peersSeletor.apiCallStatus;
@@ -87,7 +99,7 @@ export class CLNPeersComponent implements OnInit, AfterViewInit, OnDestroy {
});
this.actions.
pipe(
- takeUntil(this.unSubs[2]),
+ takeUntil(this.unSubs[3]),
filter((action) => action.type === CLNActions.SET_PEERS_CLN)
).subscribe((setPeers: any) => {
this.peerAddress = null;
@@ -163,7 +175,7 @@ export class CLNPeersComponent implements OnInit, AfterViewInit, OnDestroy {
}
}));
this.rtlEffects.closeConfirm.
- pipe(takeUntil(this.unSubs[3])).
+ pipe(takeUntil(this.unSubs[4])).
subscribe((confirmRes) => {
if (confirmRes) {
this.store.dispatch(detachPeer({ payload: { id: peerToDetach.id!, force: false } }));
@@ -191,6 +203,7 @@ export class CLNPeersComponent implements OnInit, AfterViewInit, OnDestroy {
}
};
this.peers.sort = this.sort;
+ this.peers.sort?.sort({ id: this.tableSetting.sortBy, start: this.tableSetting.sortOrder, disableClear: true });
this.peers.filterPredicate = (peer: Peer, fltr: string) => JSON.stringify(peer).toLowerCase().includes(fltr);
this.peers.paginator = this.paginator;
this.applyFilter();
diff --git a/src/app/cln/routing/failed-transactions/failed-transactions.component.html b/src/app/cln/routing/failed-transactions/failed-transactions.component.html
index ddbd6550..b2fa4009 100644
--- a/src/app/cln/routing/failed-transactions/failed-transactions.component.html
+++ b/src/app/cln/routing/failed-transactions/failed-transactions.component.html
@@ -45,7 +45,7 @@
-
+
Download CSV
@@ -53,7 +53,7 @@
|
-
+
|
diff --git a/src/app/cln/routing/forwarding-history/forwarding-history.component.html b/src/app/cln/routing/forwarding-history/forwarding-history.component.html
index a531efce..30a47bc6 100644
--- a/src/app/cln/routing/forwarding-history/forwarding-history.component.html
+++ b/src/app/cln/routing/forwarding-history/forwarding-history.component.html
@@ -43,7 +43,7 @@
-
+
Download CSV
@@ -51,7 +51,7 @@
|
-
+
|
diff --git a/src/app/cln/routing/local-failed-transactions/local-failed-transactions.component.html b/src/app/cln/routing/local-failed-transactions/local-failed-transactions.component.html
index a8cf6896..f9a44419 100644
--- a/src/app/cln/routing/local-failed-transactions/local-failed-transactions.component.html
+++ b/src/app/cln/routing/local-failed-transactions/local-failed-transactions.component.html
@@ -33,7 +33,7 @@
-
+
Download CSV
@@ -41,7 +41,7 @@
|
-
+
|
diff --git a/src/app/cln/transactions/invoices/invoices-table/lightning-invoices-table.component.html b/src/app/cln/transactions/invoices/invoices-table/lightning-invoices-table.component.html
index 6fd9ba4e..bc6bb819 100644
--- a/src/app/cln/transactions/invoices/invoices-table/lightning-invoices-table.component.html
+++ b/src/app/cln/transactions/invoices/invoices-table/lightning-invoices-table.component.html
@@ -94,7 +94,7 @@
-
+
Download CSV
diff --git a/src/app/cln/transactions/invoices/invoices-table/lightning-invoices-table.component.ts b/src/app/cln/transactions/invoices/invoices-table/lightning-invoices-table.component.ts
index 52d5cc55..0fdf016e 100644
--- a/src/app/cln/transactions/invoices/invoices-table/lightning-invoices-table.component.ts
+++ b/src/app/cln/transactions/invoices/invoices-table/lightning-invoices-table.component.ts
@@ -228,7 +228,7 @@ export class CLNLightningInvoicesTableComponent implements OnInit, AfterViewInit
this.invoices = (invs) ? new MatTableDataSource([...invs]) : new MatTableDataSource([]);
this.invoices.sortingDataAccessor = (data: any, sortHeaderId: string) => ((data[sortHeaderId] && isNaN(data[sortHeaderId])) ? data[sortHeaderId].toLocaleLowerCase() : data[sortHeaderId] ? +data[sortHeaderId] : null);
this.invoices.sort = this.sort;
- this.invoices.sort.sort({ id: this.tableSetting.sortBy, start: this.tableSetting.sortOrder, disableClear: true });
+ this.invoices.sort?.sort({ id: this.tableSetting.sortBy, start: this.tableSetting.sortOrder, disableClear: true });
this.invoices.filterPredicate = (rowData: Invoice, fltr: string) => {
const newRowData = this.datePipe.transform(new Date((rowData.paid_at || 0) * 1000), 'dd/MMM/YYYY HH:mm')?.toLowerCase()! + (this.datePipe.transform(new Date((rowData.expires_at || 0) * 1000), 'dd/MMM/YYYY HH:mm')?.toLowerCase()) + ((rowData.bolt12) ? 'bolt12' : (rowData.bolt11) ? 'bolt11' : 'keysend') + JSON.stringify(rowData).toLowerCase();
return newRowData.includes(fltr);
diff --git a/src/app/cln/transactions/offers/offer-bookmarks-table/offer-bookmarks-table.component.html b/src/app/cln/transactions/offers/offer-bookmarks-table/offer-bookmarks-table.component.html
index 9f8f6b88..129059a9 100644
--- a/src/app/cln/transactions/offers/offer-bookmarks-table/offer-bookmarks-table.component.html
+++ b/src/app/cln/transactions/offers/offer-bookmarks-table/offer-bookmarks-table.component.html
@@ -51,7 +51,7 @@
-
+
Download CSV
diff --git a/src/app/cln/transactions/offers/offer-bookmarks-table/offer-bookmarks-table.component.ts b/src/app/cln/transactions/offers/offer-bookmarks-table/offer-bookmarks-table.component.ts
index cda1610f..681793a5 100644
--- a/src/app/cln/transactions/offers/offer-bookmarks-table/offer-bookmarks-table.component.ts
+++ b/src/app/cln/transactions/offers/offer-bookmarks-table/offer-bookmarks-table.component.ts
@@ -145,7 +145,7 @@ export class CLNOfferBookmarksTableComponent implements OnInit, AfterViewInit, O
this.offersBookmarks = (OffrBMs) ? new MatTableDataSource([...OffrBMs]) : new MatTableDataSource([]);
this.offersBookmarks.sortingDataAccessor = (data: any, sortHeaderId: string) => ((data[sortHeaderId] && isNaN(data[sortHeaderId])) ? data[sortHeaderId].toLocaleLowerCase() : data[sortHeaderId] ? +data[sortHeaderId] : null);
this.offersBookmarks.sort = this.sort;
- this.offersBookmarks.sort.sort({ id: this.tableSetting.sortBy, start: this.tableSetting.sortOrder, disableClear: true });
+ this.offersBookmarks.sort?.sort({ id: this.tableSetting.sortBy, start: this.tableSetting.sortOrder, disableClear: true });
this.offersBookmarks.filterPredicate = (Ofrbm: OfferBookmark, fltr: string) => JSON.stringify(Ofrbm).toLowerCase().includes(fltr);
this.offersBookmarks.paginator = this.paginator;
this.applyFilter();
diff --git a/src/app/cln/transactions/offers/offers-table/offers-table.component.html b/src/app/cln/transactions/offers/offers-table/offers-table.component.html
index 9c47131d..1b559ac9 100644
--- a/src/app/cln/transactions/offers/offers-table/offers-table.component.html
+++ b/src/app/cln/transactions/offers/offers-table/offers-table.component.html
@@ -54,7 +54,7 @@
-
+
Download CSV
diff --git a/src/app/cln/transactions/offers/offers-table/offers-table.component.ts b/src/app/cln/transactions/offers/offers-table/offers-table.component.ts
index 23b55bfd..beede345 100644
--- a/src/app/cln/transactions/offers/offers-table/offers-table.component.ts
+++ b/src/app/cln/transactions/offers/offers-table/offers-table.component.ts
@@ -228,7 +228,7 @@ export class CLNOffersTableComponent implements OnInit, AfterViewInit, OnDestroy
this.offers = (offrs) ? new MatTableDataSource([...offrs]) : new MatTableDataSource([]);
this.offers.sortingDataAccessor = (data: any, sortHeaderId: string) => ((data[sortHeaderId] && isNaN(data[sortHeaderId])) ? data[sortHeaderId].toLocaleLowerCase() : data[sortHeaderId] ? +data[sortHeaderId] : null);
this.offers.sort = this.sort;
- this.offers.sort.sort({ id: this.tableSetting.sortBy, start: this.tableSetting.sortOrder, disableClear: true });
+ this.offers.sort?.sort({ id: this.tableSetting.sortBy, start: this.tableSetting.sortOrder, disableClear: true });
this.offers.filterPredicate = (rowData: Offer, fltr: string) => {
const newRowData = ((rowData.active) ? ' active' : ' inactive') + ((rowData.used) ? ' used' : ' unused') + ((rowData.single_use) ? ' single' : ' multiple') + JSON.stringify(rowData).toLowerCase();
if (fltr === 'active' || fltr === 'inactive' || fltr === 'used' || fltr === 'unused' || fltr === 'single' || fltr === 'multiple') {
diff --git a/src/app/cln/transactions/payments/lightning-payments.component.html b/src/app/cln/transactions/payments/lightning-payments.component.html
index 836ffc10..b981a662 100644
--- a/src/app/cln/transactions/payments/lightning-payments.component.html
+++ b/src/app/cln/transactions/payments/lightning-payments.component.html
@@ -94,7 +94,7 @@
-
+
Download CSV
@@ -102,7 +102,7 @@
|
-
+
|
diff --git a/src/app/cln/transactions/payments/lightning-payments.component.scss b/src/app/cln/transactions/payments/lightning-payments.component.scss
index 02d06c0e..9d041c91 100644
--- a/src/app/cln/transactions/payments/lightning-payments.component.scss
+++ b/src/app/cln/transactions/payments/lightning-payments.component.scss
@@ -18,12 +18,14 @@
min-height: 4.8rem;
& .btn-mpp-expand {
- width: 9rem;
+ min-width: 10rem;
+ width: 10rem;
}
& .btn-mpp-info {
- margin-top: 0.5rem;
- width: 9rem;
+ margin-top: 0.5rem;
+ min-width: 9rem;
+ width: 9rem;
}
}
diff --git a/src/app/cln/transactions/payments/lightning-payments.component.ts b/src/app/cln/transactions/payments/lightning-payments.component.ts
index 7d5ee3ca..a1880ee7 100644
--- a/src/app/cln/transactions/payments/lightning-payments.component.ts
+++ b/src/app/cln/transactions/payments/lightning-payments.component.ts
@@ -299,7 +299,7 @@ export class CLNLightningPaymentsComponent implements OnInit, AfterViewInit, OnD
this.payments = (payments) ? new MatTableDataSource([...payments]) : new MatTableDataSource([]);
this.payments.sortingDataAccessor = (data: any, sortHeaderId: string) => ((data[sortHeaderId] && isNaN(data[sortHeaderId])) ? data[sortHeaderId].toLocaleLowerCase() : data[sortHeaderId] ? +data[sortHeaderId] : null);
this.payments.sort = this.sort;
- this.payments.sort.sort({ id: this.tableSetting.sortBy, start: this.tableSetting.sortOrder, disableClear: true });
+ this.payments.sort?.sort({ id: this.tableSetting.sortBy, start: this.tableSetting.sortOrder, disableClear: true });
this.payments.filterPredicate = (rowData: Payment, fltr: string) => {
const newRowData = ((rowData.created_at) ? this.datePipe.transform(new Date(rowData.created_at * 1000), 'dd/MMM/YYYY HH:mm')?.toLowerCase() : '') + ((rowData.bolt12) ? 'bolt12' : (rowData.bolt11) ? 'bolt11' : 'keysend') + JSON.stringify(rowData).toLowerCase();
return newRowData.includes(fltr);
diff --git a/src/app/eclair/graph/query-routes/query-routes.component.html b/src/app/eclair/graph/query-routes/query-routes.component.html
index 28f516bd..527185da 100644
--- a/src/app/eclair/graph/query-routes/query-routes.component.html
+++ b/src/app/eclair/graph/query-routes/query-routes.component.html
@@ -48,7 +48,7 @@
Actions |
-
+
|
diff --git a/src/app/eclair/graph/query-routes/query-routes.component.scss b/src/app/eclair/graph/query-routes/query-routes.component.scss
index f5961ac5..3d0e9c13 100644
--- a/src/app/eclair/graph/query-routes/query-routes.component.scss
+++ b/src/app/eclair/graph/query-routes/query-routes.component.scss
@@ -1,6 +1,5 @@
.mat-column-actions {
- flex: 0 0 5%;
- width: 5%;
+ min-height: 4.8rem;
}
.mat-column-pubkey_alias {
diff --git a/src/app/eclair/on-chain/on-chain-transaction-history/on-chain-transaction-history.component.html b/src/app/eclair/on-chain/on-chain-transaction-history/on-chain-transaction-history.component.html
index d529bdcd..e4d8e400 100644
--- a/src/app/eclair/on-chain/on-chain-transaction-history/on-chain-transaction-history.component.html
+++ b/src/app/eclair/on-chain/on-chain-transaction-history/on-chain-transaction-history.component.html
@@ -39,7 +39,7 @@
-
+
Download CSV
@@ -47,7 +47,7 @@
|
-
+
|
diff --git a/src/app/eclair/peers-channels/channels/channels-tables/channel-inactive-table/channel-inactive-table.component.html b/src/app/eclair/peers-channels/channels/channels-tables/channel-inactive-table/channel-inactive-table.component.html
index 0d451ad5..a225854c 100644
--- a/src/app/eclair/peers-channels/channels/channels-tables/channel-inactive-table/channel-inactive-table.component.html
+++ b/src/app/eclair/peers-channels/channels/channels-tables/channel-inactive-table/channel-inactive-table.component.html
@@ -51,7 +51,7 @@
-
+
Download CSV
diff --git a/src/app/eclair/peers-channels/channels/channels-tables/channel-inactive-table/channel-inactive-table.component.scss b/src/app/eclair/peers-channels/channels/channels-tables/channel-inactive-table/channel-inactive-table.component.scss
index ff0e307d..0a4bdf06 100644
--- a/src/app/eclair/peers-channels/channels/channels-tables/channel-inactive-table/channel-inactive-table.component.scss
+++ b/src/app/eclair/peers-channels/channels/channels-tables/channel-inactive-table/channel-inactive-table.component.scss
@@ -35,10 +35,4 @@
.mat-column-actions {
min-height: 4.8rem;
- & .bordered-box.table-actions-select {
- flex: 0 0 100%;
- @include for_screensize(phone) {
- flex: 0 0 80%;
- }
- }
}
diff --git a/src/app/eclair/peers-channels/channels/channels-tables/channel-open-table/channel-open-table.component.html b/src/app/eclair/peers-channels/channels/channels-tables/channel-open-table/channel-open-table.component.html
index aff08e0e..7b149c37 100644
--- a/src/app/eclair/peers-channels/channels/channels-tables/channel-open-table/channel-open-table.component.html
+++ b/src/app/eclair/peers-channels/channels/channels-tables/channel-open-table/channel-open-table.component.html
@@ -57,7 +57,7 @@
-
+
Update Fee Policy
diff --git a/src/app/eclair/peers-channels/channels/channels-tables/channel-open-table/channel-open-table.component.scss b/src/app/eclair/peers-channels/channels/channels-tables/channel-open-table/channel-open-table.component.scss
index 4147e3d9..3be0e417 100644
--- a/src/app/eclair/peers-channels/channels/channels-tables/channel-open-table/channel-open-table.component.scss
+++ b/src/app/eclair/peers-channels/channels/channels-tables/channel-open-table/channel-open-table.component.scss
@@ -41,13 +41,4 @@
.mat-column-actions {
min-height: 4.8rem;
- & .bordered-box.table-actions-select {
- flex: 0 0 100%;
- @include for_screensize(tab-port) {
- flex: 0 0 90%;
- }
- @include for_screensize(phone) {
- flex: 0 0 80%;
- }
- }
}
diff --git a/src/app/eclair/peers-channels/channels/channels-tables/channel-pending-table/channel-pending-table.component.html b/src/app/eclair/peers-channels/channels/channels-tables/channel-pending-table/channel-pending-table.component.html
index aa2ad78d..1af24c93 100644
--- a/src/app/eclair/peers-channels/channels/channels-tables/channel-pending-table/channel-pending-table.component.html
+++ b/src/app/eclair/peers-channels/channels/channels-tables/channel-pending-table/channel-pending-table.component.html
@@ -28,7 +28,7 @@
-
+
Download CSV
@@ -36,7 +36,7 @@
|
-
+
|
diff --git a/src/app/eclair/peers-channels/peers/peers.component.html b/src/app/eclair/peers-channels/peers/peers.component.html
index 65e5328b..cdae653f 100644
--- a/src/app/eclair/peers-channels/peers/peers.component.html
+++ b/src/app/eclair/peers-channels/peers/peers.component.html
@@ -47,7 +47,7 @@
-
+
Download CSV
@@ -55,7 +55,7 @@
|
-
+
View Info
diff --git a/src/app/eclair/routing/forwarding-history/forwarding-history.component.html b/src/app/eclair/routing/forwarding-history/forwarding-history.component.html
index 750a2842..b8099eff 100644
--- a/src/app/eclair/routing/forwarding-history/forwarding-history.component.html
+++ b/src/app/eclair/routing/forwarding-history/forwarding-history.component.html
@@ -38,7 +38,7 @@
-
+
Download CSV
@@ -46,7 +46,7 @@
|
-
+
|
diff --git a/src/app/eclair/transactions/invoices/lightning-invoices.component.html b/src/app/eclair/transactions/invoices/lightning-invoices.component.html
index c8ece86b..cc4da0ec 100644
--- a/src/app/eclair/transactions/invoices/lightning-invoices.component.html
+++ b/src/app/eclair/transactions/invoices/lightning-invoices.component.html
@@ -65,7 +65,7 @@
-
+
Download CSV
diff --git a/src/app/eclair/transactions/payments/lightning-payments.component.html b/src/app/eclair/transactions/payments/lightning-payments.component.html
index 7373751a..5df8001f 100644
--- a/src/app/eclair/transactions/payments/lightning-payments.component.html
+++ b/src/app/eclair/transactions/payments/lightning-payments.component.html
@@ -53,7 +53,7 @@
-
+
Download CSV
@@ -61,7 +61,7 @@
|
-
+
|
diff --git a/src/app/lnd/backup/channel-backup-table/channel-backup-table.component.html b/src/app/lnd/backup/channel-backup-table/channel-backup-table.component.html
index 924da3a5..eab6f3de 100644
--- a/src/app/lnd/backup/channel-backup-table/channel-backup-table.component.html
+++ b/src/app/lnd/backup/channel-backup-table/channel-backup-table.component.html
@@ -33,7 +33,7 @@
Actions |
-
+
View Info
diff --git a/src/app/lnd/graph/query-routes/query-routes.component.html b/src/app/lnd/graph/query-routes/query-routes.component.html
index 26b3bfed..0ed74c1f 100644
--- a/src/app/lnd/graph/query-routes/query-routes.component.html
+++ b/src/app/lnd/graph/query-routes/query-routes.component.html
@@ -55,7 +55,7 @@
Actions |
-
+
|
diff --git a/src/app/lnd/graph/query-routes/query-routes.component.scss b/src/app/lnd/graph/query-routes/query-routes.component.scss
index f5961ac5..3d0e9c13 100644
--- a/src/app/lnd/graph/query-routes/query-routes.component.scss
+++ b/src/app/lnd/graph/query-routes/query-routes.component.scss
@@ -1,6 +1,5 @@
.mat-column-actions {
- flex: 0 0 5%;
- width: 5%;
+ min-height: 4.8rem;
}
.mat-column-pubkey_alias {
diff --git a/src/app/lnd/on-chain/utxo-tables/on-chain-transaction-history/on-chain-transaction-history.component.html b/src/app/lnd/on-chain/utxo-tables/on-chain-transaction-history/on-chain-transaction-history.component.html
index 1d5a3d9e..cb6e96c6 100644
--- a/src/app/lnd/on-chain/utxo-tables/on-chain-transaction-history/on-chain-transaction-history.component.html
+++ b/src/app/lnd/on-chain/utxo-tables/on-chain-transaction-history/on-chain-transaction-history.component.html
@@ -38,7 +38,7 @@
-
+
Download CSV
@@ -46,7 +46,7 @@
|
-
+
|
diff --git a/src/app/lnd/on-chain/utxo-tables/utxos/utxos.component.html b/src/app/lnd/on-chain/utxo-tables/utxos/utxos.component.html
index ab0c296c..5a17c097 100644
--- a/src/app/lnd/on-chain/utxo-tables/utxos/utxos.component.html
+++ b/src/app/lnd/on-chain/utxo-tables/utxos/utxos.component.html
@@ -44,7 +44,7 @@
-
+
Download CSV
diff --git a/src/app/lnd/peers-channels/channels/channels-tables/channel-active-htlcs-table/channel-active-htlcs-table.component.html b/src/app/lnd/peers-channels/channels/channels-tables/channel-active-htlcs-table/channel-active-htlcs-table.component.html
index a72322e6..885e380a 100644
--- a/src/app/lnd/peers-channels/channels/channels-tables/channel-active-htlcs-table/channel-active-htlcs-table.component.html
+++ b/src/app/lnd/peers-channels/channels/channels-tables/channel-active-htlcs-table/channel-active-htlcs-table.component.html
@@ -61,7 +61,7 @@
-
+
Download CSV
diff --git a/src/app/lnd/peers-channels/channels/channels-tables/channel-active-htlcs-table/channel-active-htlcs-table.component.scss b/src/app/lnd/peers-channels/channels/channels-tables/channel-active-htlcs-table/channel-active-htlcs-table.component.scss
index 6510d9e9..7c4d3ffc 100644
--- a/src/app/lnd/peers-channels/channels/channels-tables/channel-active-htlcs-table/channel-active-htlcs-table.component.scss
+++ b/src/app/lnd/peers-channels/channels/channels-tables/channel-active-htlcs-table/channel-active-htlcs-table.component.scss
@@ -19,11 +19,13 @@
min-height: 4.8rem;
& .btn-htlc-expand {
- width: 9rem;
+ min-width: 10rem;
+ width: 10rem;
}
& .btn-htlc-info {
- margin-top: 0.5rem;
+ margin-top: 0.5rem;
+ min-width: 9rem;
width: 9rem;
}
}
diff --git a/src/app/lnd/peers-channels/channels/channels-tables/channel-closed-table/channel-closed-table.component.html b/src/app/lnd/peers-channels/channels/channels-tables/channel-closed-table/channel-closed-table.component.html
index 0e656996..b55d663d 100644
--- a/src/app/lnd/peers-channels/channels/channels-tables/channel-closed-table/channel-closed-table.component.html
+++ b/src/app/lnd/peers-channels/channels/channels-tables/channel-closed-table/channel-closed-table.component.html
@@ -38,7 +38,7 @@
-
+
Download CSV
@@ -47,7 +47,7 @@
|
-
+
|
diff --git a/src/app/lnd/peers-channels/channels/channels-tables/channel-open-table/channel-open-table.component.scss b/src/app/lnd/peers-channels/channels/channels-tables/channel-open-table/channel-open-table.component.scss
index c9e87e45..4cfc14d8 100644
--- a/src/app/lnd/peers-channels/channels/channels-tables/channel-open-table/channel-open-table.component.scss
+++ b/src/app/lnd/peers-channels/channels/channels-tables/channel-open-table/channel-open-table.component.scss
@@ -43,13 +43,4 @@
.mat-column-actions {
min-height: 4.8rem;
- & .bordered-box.table-actions-select {
- flex: 0 0 100%;
- @include for_screensize(tab-port) {
- flex: 0 0 90%;
- }
- @include for_screensize(phone) {
- flex: 0 0 80%;
- }
- }
}
diff --git a/src/app/lnd/peers-channels/channels/channels-tables/channel-pending-table/channel-pending-table.component.html b/src/app/lnd/peers-channels/channels/channels-tables/channel-pending-table/channel-pending-table.component.html
index cf5b4f83..044e87a1 100644
--- a/src/app/lnd/peers-channels/channels/channels-tables/channel-pending-table/channel-pending-table.component.html
+++ b/src/app/lnd/peers-channels/channels/channels-tables/channel-pending-table/channel-pending-table.component.html
@@ -76,7 +76,7 @@
Actions
-
+
@@ -125,7 +125,7 @@
Actions
-
+
@@ -180,7 +180,7 @@
Actions
-
+
diff --git a/src/app/lnd/peers-channels/peers/peers.component.html b/src/app/lnd/peers-channels/peers/peers.component.html
index a9441312..690cd38d 100644
--- a/src/app/lnd/peers-channels/peers/peers.component.html
+++ b/src/app/lnd/peers-channels/peers/peers.component.html
@@ -40,7 +40,7 @@
-
+
Download CSV
@@ -48,7 +48,7 @@
|
-
+
View Info
diff --git a/src/app/lnd/peers-channels/peers/peers.component.scss b/src/app/lnd/peers-channels/peers/peers.component.scss
index 1dd36251..742bdbab 100644
--- a/src/app/lnd/peers-channels/peers/peers.component.scss
+++ b/src/app/lnd/peers-channels/peers/peers.component.scss
@@ -15,7 +15,6 @@
.mat-column-actions {
min-height: 4.8rem;
- flex: 1 1 10%;
}
.mat-column-sat_sent, .mat-column-sat_recv, .mat-column-ping_time {
diff --git a/src/app/lnd/routing/forwarding-history/forwarding-history.component.html b/src/app/lnd/routing/forwarding-history/forwarding-history.component.html
index c7d1e096..850a5d63 100644
--- a/src/app/lnd/routing/forwarding-history/forwarding-history.component.html
+++ b/src/app/lnd/routing/forwarding-history/forwarding-history.component.html
@@ -35,7 +35,7 @@
-
+
Download CSV
@@ -43,7 +43,7 @@
|
-
+
|
diff --git a/src/app/lnd/routing/routing-peers/routing-peers.component.html b/src/app/lnd/routing/routing-peers/routing-peers.component.html
index a57b4b29..e68ee735 100644
--- a/src/app/lnd/routing/routing-peers/routing-peers.component.html
+++ b/src/app/lnd/routing/routing-peers/routing-peers.component.html
@@ -31,7 +31,7 @@
Actions |
-
+
|
@@ -78,7 +78,7 @@
Actions |
-
+
|
diff --git a/src/app/lnd/transactions/invoices/lightning-invoices.component.html b/src/app/lnd/transactions/invoices/lightning-invoices.component.html
index 3efa9deb..d09e94c8 100644
--- a/src/app/lnd/transactions/invoices/lightning-invoices.component.html
+++ b/src/app/lnd/transactions/invoices/lightning-invoices.component.html
@@ -60,7 +60,7 @@
-
+
Download CSV
diff --git a/src/app/lnd/transactions/payments/lightning-payments.component.html b/src/app/lnd/transactions/payments/lightning-payments.component.html
index ed56206a..cf2d6ccd 100644
--- a/src/app/lnd/transactions/payments/lightning-payments.component.html
+++ b/src/app/lnd/transactions/payments/lightning-payments.component.html
@@ -57,7 +57,7 @@
-
+
Download CSV
@@ -65,7 +65,7 @@
|
-
+
|
diff --git a/src/app/lnd/transactions/payments/lightning-payments.component.scss b/src/app/lnd/transactions/payments/lightning-payments.component.scss
index e739014a..8f54d7fd 100644
--- a/src/app/lnd/transactions/payments/lightning-payments.component.scss
+++ b/src/app/lnd/transactions/payments/lightning-payments.component.scss
@@ -14,12 +14,14 @@
min-height: 4.8rem;
& .btn-htlc-expand {
- width: 9rem;
+ min-width: 10rem;
+ width: 10rem;
}
& .btn-htlc-info {
- margin-top: 0.5rem;
- width: 9rem;
+ margin-top: 0.5rem;
+ min-width: 9rem;
+ width: 9rem;
}
}
diff --git a/src/app/shared/components/ln-services/boltz/swaps/swaps.component.html b/src/app/shared/components/ln-services/boltz/swaps/swaps.component.html
index cc4f23d1..5d5c24f1 100755
--- a/src/app/shared/components/ln-services/boltz/swaps/swaps.component.html
+++ b/src/app/shared/components/ln-services/boltz/swaps/swaps.component.html
@@ -54,7 +54,7 @@
-
+
Download CSV
@@ -63,7 +63,7 @@
|
+ (click)="onSwapClick(swap, $event)"class="table-actions-button">View Info
|
diff --git a/src/app/shared/components/ln-services/loop/swaps/swaps.component.html b/src/app/shared/components/ln-services/loop/swaps/swaps.component.html
index 6194ad09..8c0fc066 100755
--- a/src/app/shared/components/ln-services/loop/swaps/swaps.component.html
+++ b/src/app/shared/components/ln-services/loop/swaps/swaps.component.html
@@ -57,7 +57,7 @@
-
+
Download CSV
@@ -66,7 +66,7 @@
|
+ (click)="onSwapClick(swap, $event)"class="table-actions-button">View Info
|
diff --git a/src/app/shared/components/node-config/page-settings/page-settings.component.html b/src/app/shared/components/node-config/page-settings/page-settings.component.html
index b5a0dec8..9cb54a38 100644
--- a/src/app/shared/components/node-config/page-settings/page-settings.component.html
+++ b/src/app/shared/components/node-config/page-settings/page-settings.component.html
@@ -7,7 +7,7 @@
- {{page.pageId | titlecase}}
+ {{page.pageId | camelcase}}
@@ -35,7 +35,7 @@
- = 2 && !table.columnSelectionSM.includes(field))">
+ = 3 && !table.columnSelectionSM.includes(field))">
{{field | camelcaseWithReplace:'_'}}
diff --git a/src/app/shared/components/transactions-report-table/transactions-report-table.component.html b/src/app/shared/components/transactions-report-table/transactions-report-table.component.html
index 1cccb8b0..aadc998e 100644
--- a/src/app/shared/components/transactions-report-table/transactions-report-table.component.html
+++ b/src/app/shared/components/transactions-report-table/transactions-report-table.component.html
@@ -31,7 +31,7 @@
-
+
Download CSV
@@ -39,7 +39,7 @@
|
-
+
|
diff --git a/src/app/shared/models/clnModels.ts b/src/app/shared/models/clnModels.ts
index 50490bad..cf9fac3c 100644
--- a/src/app/shared/models/clnModels.ts
+++ b/src/app/shared/models/clnModels.ts
@@ -318,7 +318,8 @@ export interface Channel {
their_channel_reserve_satoshis?: string;
our_channel_reserve_satoshis?: string;
spendable_msatoshi?: string;
- balancedness?: number; // Between -1 to +1
+ direction?: number;
+ balancedness?: number; // Between 0-1-0
}
export interface ChannelEdge {
diff --git a/src/app/shared/models/lndModels.ts b/src/app/shared/models/lndModels.ts
index ec1172d8..e4cbcf9d 100644
--- a/src/app/shared/models/lndModels.ts
+++ b/src/app/shared/models/lndModels.ts
@@ -81,7 +81,7 @@ export interface Channel {
uptime_str?: string;
lifetime?: string;
static_remote_key?: boolean;
- balancedness?: number; // Between -1 to +1
+ balancedness?: number; // Between 0-1-0
}
export interface PendingChannel {
diff --git a/src/app/shared/services/consts-enums-functions.ts b/src/app/shared/services/consts-enums-functions.ts
index 56b722b7..39eb6b6a 100644
--- a/src/app/shared/services/consts-enums-functions.ts
+++ b/src/app/shared/services/consts-enums-functions.ts
@@ -683,6 +683,17 @@ export const CLN_DEFAULT_PAGE_SETTINGS: PageSettingsCLN[] = [
columnSelectionSM: ['txid', 'value'],
columnSelection: ['txid', 'output', 'value', 'blockheight'] }
] },
+ { pageId: 'peers/channels', tables: [
+ { tableId: 'open_channels', recordsPerPage: PAGE_SIZE, sortBy: 'msatoshi_to_us', sortOrder: SortOrderEnum.DESCENDING,
+ columnSelectionSM: ['alias', 'msatoshi_to_us', 'msatoshi_to_them'],
+ columnSelection: ['short_channel_id', 'alias', 'msatoshi_to_us', 'msatoshi_to_them', 'balancedness'] },
+ { tableId: 'pending_inactive_channels', recordsPerPage: PAGE_SIZE, sortBy: 'state', sortOrder: SortOrderEnum.DESCENDING,
+ columnSelectionSM: ['alias', 'state'],
+ columnSelection: ['alias', 'connected', 'state', 'msatoshi_total'] },
+ { tableId: 'peers', recordsPerPage: PAGE_SIZE, sortBy: 'alias', sortOrder: SortOrderEnum.ASCENDING,
+ columnSelectionSM: ['alias', 'id'],
+ columnSelection: ['alias', 'id', 'netaddr'] }
+ ] },
{ pageId: 'transactions', tables: [
{ tableId: 'payments', recordsPerPage: PAGE_SIZE, sortBy: 'created_at', sortOrder: SortOrderEnum.DESCENDING,
columnSelectionSM: ['created_at', 'msatoshi'],
@@ -708,6 +719,18 @@ export const CLN_TABLES_DEF = {
maxColumns: 7,
allowedColumns: ['txid', 'address', 'scriptpubkey', 'output', 'value', 'blockheight', 'reserved']
},
+ open_channels: {
+ maxColumns: 8,
+ allowedColumns: ['short_channel_id', 'alias', 'id', 'channel_id', 'funding_txid', 'connected', 'our_channel_reserve_satoshis', 'their_channel_reserve_satoshis', 'msatoshi_total', 'spendable_msatoshi', 'msatoshi_to_us', 'msatoshi_to_them', 'balancedness']
+ },
+ pending_inactive_channels: {
+ maxColumns: 8,
+ allowedColumns: ['alias', 'id', 'channel_id', 'funding_txid', 'connected', 'state', 'our_channel_reserve_satoshis', 'their_channel_reserve_satoshis', 'msatoshi_total', 'spendable_msatoshi', 'msatoshi_to_us', 'msatoshi_to_them']
+ },
+ peers: {
+ maxColumns: 3,
+ allowedColumns: ['alias', 'id', 'netaddr']
+ },
payments: {
maxColumns: 5,
allowedColumns: ['created_at', 'type', 'payment_hash', 'bolt11', 'destination', 'memo', 'label', 'msatoshi_sent', 'msatoshi']
diff --git a/src/app/shared/theme/styles/theme-color.scss b/src/app/shared/theme/styles/theme-color.scss
index da221582..e2e5c267 100644
--- a/src/app/shared/theme/styles/theme-color.scss
+++ b/src/app/shared/theme/styles/theme-color.scss
@@ -286,6 +286,11 @@
}
}
+ .table-actions-button {
+ min-width: 10rem;
+ width: 10rem;
+ }
+
.mat-select-panel .mat-option.mat-active {
background: none;
}
| | | | | | | | | | | | | | | | | |