From ca268b8e85763660b1ba174da09e2ef7ea01a5e3 Mon Sep 17 00:00:00 2001 From: Jack Mallers Date: Mon, 4 Jun 2018 14:43:08 -0500 Subject: [PATCH 1/2] feature(external block explorer link): change icon to external link and allow users to link to channels in explorer --- app/components/Contacts/Network.js | 6 +++--- app/preload.js | 1 + 2 files changed, 4 insertions(+), 3 deletions(-) create mode 100644 app/preload.js diff --git a/app/components/Contacts/Network.js b/app/components/Contacts/Network.js index 3810f183..3d92acbb 100644 --- a/app/components/Contacts/Network.js +++ b/app/components/Contacts/Network.js @@ -2,8 +2,8 @@ import React, { Component } from 'react' import PropTypes from 'prop-types' import find from 'lodash/find' import Isvg from 'react-inlinesvg' -import { FaAngleDown, FaCircle, FaRepeat } from 'react-icons/lib/fa' -import { btc } from 'utils' +import { FaExternalLink, FaCircle, FaRepeat, FaAngleDown } from 'react-icons/lib/fa' +import { btc, blockExplorer } from 'utils' import plus from 'icons/plus.svg' import search from 'icons/search.svg' @@ -223,7 +223,7 @@ class Network extends Component { {displayNodeName(channel)} { - selectedChannel === channel && + selectedChannel === channel && blockExplorer.showTransaction(channel.channel_point.split(':')[0])}> } diff --git a/app/preload.js b/app/preload.js new file mode 100644 index 00000000..a90deef8 --- /dev/null +++ b/app/preload.js @@ -0,0 +1 @@ +window.ipcRenderer = require('electron').ipcRenderer \ No newline at end of file From cc9921a6d90ad94523998adfcf6ad52d0d1de660 Mon Sep 17 00:00:00 2001 From: Jack Mallers Date: Wed, 6 Jun 2018 15:19:51 -0500 Subject: [PATCH 2/2] fix(lint): fix lint errors --- app/components/Contacts/Network.js | 5 ++++- app/preload.js | 1 - 2 files changed, 4 insertions(+), 2 deletions(-) delete mode 100644 app/preload.js diff --git a/app/components/Contacts/Network.js b/app/components/Contacts/Network.js index 3d92acbb..53495333 100644 --- a/app/components/Contacts/Network.js +++ b/app/components/Contacts/Network.js @@ -223,7 +223,10 @@ class Network extends Component { {displayNodeName(channel)} { - selectedChannel === channel && blockExplorer.showTransaction(channel.channel_point.split(':')[0])}> + selectedChannel === channel && + blockExplorer.showTransaction(channel.channel_point.split(':')[0])}> + + } diff --git a/app/preload.js b/app/preload.js deleted file mode 100644 index a90deef8..00000000 --- a/app/preload.js +++ /dev/null @@ -1 +0,0 @@ -window.ipcRenderer = require('electron').ipcRenderer \ No newline at end of file