File tree Expand file tree Collapse file tree 8 files changed +20
-9
lines changed
Expand file tree Collapse file tree 8 files changed +20
-9
lines changed Original file line number Diff line number Diff line change 1+ ! ga.js
Original file line number Diff line number Diff line change 11{
22 "name" : " lightning-decoder" ,
3- "version" : " 0.2 .0" ,
3+ "version" : " 0.3 .0" ,
44 "author" : {
55 "email" : " andrerfneves@protonmail.com" ,
66 "name" : " André Neves" ,
77 "url" : " https://andrenev.es"
88 },
9+ "license" : " MIT" ,
910 "dependencies" : {
1011 "bech32" : " ^1.1.2" ,
1112 "bitcoinjs-lib" : " ^3.3.1" ,
Original file line number Diff line number Diff line change @@ -153,9 +153,10 @@ class App extends PureComponent {
153153 const { decodedInvoice } = this . state ;
154154 const tags = decodedInvoice [ key ] ;
155155
156- const renderTag = ( tag ) => ( typeof tag . data !== 'string' ) ?
157- renderNestedTag ( tag ) :
158- renderNormalTag ( tag ) ;
156+ const renderTag = ( tag ) => (
157+ typeof tag . data !== 'string' &&
158+ typeof tag . data !== 'number'
159+ ) ? renderNestedTag ( tag ) : renderNormalTag ( tag ) ;
159160
160161 const renderNestedTag = ( tag ) => (
161162 < div className = 'invoice__item invoice__item--nested' >
@@ -270,4 +271,4 @@ class App extends PureComponent {
270271 }
271272}
272273
273- export default App ;
274+ export { App } ;
Original file line number Diff line number Diff line change 44 allSizes : 16 / 16 * 1rem ,
55 smallMobile : 400 / 16 * 1rem ,
66 mobile : 768 / 16 * 1rem ,
7- smallTablet : 850 / 16 * 1rem ,
7+ smallTablet : 900 / 16 * 1rem ,
88 tablet : 1024 / 16 * 1rem ,
99 smallDesktop : 1180 / 16 * 1rem ,
1010 desktop : 1280 / 16 * 1rem ,
Original file line number Diff line number Diff line change 1313 border : $border ;
1414 outline : none ;
1515 color : $text-primary ;
16- min-width : 500 px ;
16+ min-width : $container-width ;
1717 font-family : $font-family ;
1818 position : relative ;
1919 }
Original file line number Diff line number Diff line change @@ -16,4 +16,6 @@ export const PAYMENT_HASH_KEY = 'payment_hash';
1616export const FALLBACK_ADDRESS_KEY = 'fallback_address' ;
1717export const CODE_KEY = 'code' ;
1818export const ADDRESS_KEY = 'address' ;
19- export const ADDRESS_HASH_KEY = 'addressHash' ;
19+ export const ADDRESS_HASH_KEY = 'addressHash' ;
20+ export const DESCRIPTION_KEY = 'description' ;
21+ export const EXPIRY_HTLC = 'min_final_cltv_expiry' ;
Original file line number Diff line number Diff line change @@ -4,7 +4,7 @@ import ReactDOM from 'react-dom';
44import ReactGA from 'react-ga' ;
55
66// Main Component
7- import App from './app' ;
7+ import { App } from './app' ;
88
99// Constants
1010import { GA_CODE } from './constants/ga' ;
Original file line number Diff line number Diff line change @@ -15,6 +15,8 @@ import {
1515 ADDRESS_HASH_KEY ,
1616 ADDRESS_KEY ,
1717 CODE_KEY ,
18+ DESCRIPTION_KEY ,
19+ EXPIRY_HTLC ,
1820} from '../constants/keys' ;
1921
2022export const formatDetailsKey = ( key : string ) => {
@@ -49,6 +51,10 @@ export const formatDetailsKey = (key: string) => {
4951 return 'Address' ;
5052 case CODE_KEY :
5153 return 'Code' ;
54+ case DESCRIPTION_KEY :
55+ return 'Description' ;
56+ case EXPIRY_HTLC :
57+ return 'Expiry CLTV' ;
5258 default :
5359 break ;
5460 }
You can’t perform that action at this time.
0 commit comments