mirror of
https://github.com/fullstack-cash/fullstack-gatsby-theme-bch-wallet.git
synced 2026-09-21 16:52:06 -07:00
Removing commented code
This commit is contained in:
+23
-106
@@ -3,12 +3,8 @@ import './footer.css'
|
|||||||
import { Row, Col } from 'adminlte-2-react'
|
import { Row, Col } from 'adminlte-2-react'
|
||||||
import { FontAwesomeIcon } from '@fortawesome/react-fontawesome'
|
import { FontAwesomeIcon } from '@fortawesome/react-fontawesome'
|
||||||
import { faGithub } from '@fortawesome/free-brands-svg-icons'
|
import { faGithub } from '@fortawesome/free-brands-svg-icons'
|
||||||
// import { getWalletInfo } from '../localWallet'
|
|
||||||
import PropTypes from 'prop-types'
|
import PropTypes from 'prop-types'
|
||||||
|
|
||||||
// Get the IPFS hash from the BCH Blockchain.
|
|
||||||
// import MemoGet from 'memo-get-gatsby'
|
|
||||||
|
|
||||||
// Get the IPFS hash from the BCH Blockchain.
|
// Get the IPFS hash from the BCH Blockchain.
|
||||||
import Memo from '../../services/memo-hash'
|
import Memo from '../../services/memo-hash'
|
||||||
const siteConfig = require('../site-config')
|
const siteConfig = require('../site-config')
|
||||||
@@ -29,23 +25,17 @@ class Footer extends React.Component {
|
|||||||
bchWallet: props.bchWallet,
|
bchWallet: props.bchWallet,
|
||||||
bchAddr: siteConfig.memoAddr
|
bchAddr: siteConfig.memoAddr
|
||||||
})
|
})
|
||||||
|
|
||||||
// memo-get-gatsby Instance
|
|
||||||
// this.memoGet = _this.instantiateMemoLib()
|
|
||||||
}
|
}
|
||||||
|
|
||||||
async componentDidMount () {
|
async componentDidMount () {
|
||||||
// Get hash using memo service
|
// Get hash using memo service
|
||||||
await this.handleMemoService()
|
await this.handleMemoService()
|
||||||
|
|
||||||
// Get hash using memo-get-gatsby library
|
|
||||||
// await this.handleMemoGet()
|
|
||||||
}
|
}
|
||||||
|
|
||||||
async handleMemoService () {
|
async handleMemoService () {
|
||||||
// This is a hard-coded hash or 'checkpoint' to use in times when the
|
// This is a hard-coded hash or 'checkpoint' to use in times when the
|
||||||
// connection fails.
|
// connection fails.
|
||||||
const hash = 'QmXbaYeTMMsQnLYpthpfoUJhz8o1DWqjoUwLUhC9KFUrAW'
|
const hash = 'QmXT85Xoi7xMRD9m7Ta4Cx8Yrsd2WSzLrq2VRo26KW4xLu'
|
||||||
|
|
||||||
// Try to retrieve the hash from the BCH blockchain.
|
// Try to retrieve the hash from the BCH blockchain.
|
||||||
try {
|
try {
|
||||||
@@ -65,110 +55,63 @@ class Footer extends React.Component {
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
// Get hash using memo-get-gatsby
|
|
||||||
// async handleMemoGet () {
|
|
||||||
// try {
|
|
||||||
// const addr = 'bitcoincash:qq8mk8etntclfdkny2aknh4ylc0uaewalszh5eytnr'
|
|
||||||
// const hash = await _this.memoGet.read(addr)
|
|
||||||
// console.log(`hash: ${hash}`)
|
|
||||||
//
|
|
||||||
// this.setState({
|
|
||||||
// ipfsHash: hash,
|
|
||||||
// ipfsHashLink: `https://ipfs-gateway.fullstack.cash/ipfs/${hash}`
|
|
||||||
// })
|
|
||||||
// } catch (err) {
|
|
||||||
// console.error('Error trying to retrieve IPFS hash for the site: ', err)
|
|
||||||
//
|
|
||||||
// // Manually set an old hash.
|
|
||||||
// const hash = 'QmVm1y1MX4YPzmgQiAafY96Pq7j6GTNMFNuvHki1jAwxYg'
|
|
||||||
// this.setState({
|
|
||||||
// ipfsHash: hash,
|
|
||||||
// ipfsHashLink: `https://ipfs-gateway.fullstack.cash/ipfs/${hash}`
|
|
||||||
// })
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// // const bchjs = new BCHJS()
|
|
||||||
// // const balance = await bchjs.Blockbook.balance(addr)
|
|
||||||
// // console.log(`balance: ${JSON.stringify(balance, null, 2)}`)
|
|
||||||
// }
|
|
||||||
|
|
||||||
// Instantiate the library with the
|
|
||||||
// bchjs options established in the configuration section
|
|
||||||
// instantiateMemoLib () {
|
|
||||||
// // Get wallet info
|
|
||||||
// const localStorageInfo = getWalletInfo()
|
|
||||||
//
|
|
||||||
// // Get bchjs options
|
|
||||||
// const jwtToken = localStorageInfo.JWT
|
|
||||||
// const restURL = localStorageInfo.selectedServer
|
|
||||||
// const bchjsOptions = {}
|
|
||||||
//
|
|
||||||
// if (jwtToken) {
|
|
||||||
// bchjsOptions.apiToken = jwtToken
|
|
||||||
// }
|
|
||||||
// if (restURL) {
|
|
||||||
// bchjsOptions.restURL = restURL
|
|
||||||
// }
|
|
||||||
// return new MemoGet(bchjsOptions)
|
|
||||||
// }
|
|
||||||
|
|
||||||
render () {
|
render () {
|
||||||
return (
|
return (
|
||||||
<section id='footer'>
|
<section id="footer">
|
||||||
<Row className='footer-container'>
|
<Row className="footer-container">
|
||||||
<Col md={5} className='footer-section'>
|
<Col md={5} className="footer-section">
|
||||||
<Row>
|
<Row>
|
||||||
<Col md={12} className='mb-1'>
|
<Col md={12} className="mb-1">
|
||||||
<p className='section-tittle'>Produced By</p>
|
<p className="section-tittle">Produced By</p>
|
||||||
|
|
||||||
<a
|
<a
|
||||||
href='https://psfoundation.cash/'
|
href="https://psfoundation.cash/"
|
||||||
target='_blank'
|
target="_blank"
|
||||||
rel='noopener noreferrer'
|
rel="noopener noreferrer"
|
||||||
>
|
>
|
||||||
Permissionless Software Foundation
|
Permissionless Software Foundation
|
||||||
</a>
|
</a>
|
||||||
</Col>
|
</Col>
|
||||||
<Col md={12}>
|
<Col md={12}>
|
||||||
<p className='section-tittle'>Source Code</p>
|
<p className="section-tittle">Source Code</p>
|
||||||
<FontAwesomeIcon className='' size='lg' icon={faGithub} />
|
<FontAwesomeIcon className="" size="lg" icon={faGithub} />
|
||||||
<a
|
<a
|
||||||
href='https://github.com/Permissionless-Software-Foundation/gatsby-ipfs-web-wallet'
|
href="https://github.com/Permissionless-Software-Foundation/gatsby-ipfs-web-wallet"
|
||||||
target='_blank'
|
target="_blank"
|
||||||
rel='noopener noreferrer'
|
rel="noopener noreferrer"
|
||||||
>
|
>
|
||||||
Github
|
Github
|
||||||
</a>
|
</a>
|
||||||
</Col>
|
</Col>
|
||||||
</Row>
|
</Row>
|
||||||
</Col>
|
</Col>
|
||||||
<Col md={7} className='footer-section'>
|
<Col md={7} className="footer-section">
|
||||||
<div className='pull-right'>
|
<div className="pull-right">
|
||||||
<span className='section-tittle'>
|
<span className="section-tittle">
|
||||||
Ways to access this web-app
|
Ways to access this web-app
|
||||||
</span>
|
</span>
|
||||||
<ul>
|
<ul>
|
||||||
<li id='web'>
|
<li id="web">
|
||||||
<span>
|
<span>
|
||||||
<b>Web</b>
|
<b>Web</b>
|
||||||
</span>
|
</span>
|
||||||
<b>|</b>
|
<b>|</b>
|
||||||
<a href='https://wallet.fullstack.cash'>
|
<a href="https://wallet.fullstack.cash">
|
||||||
wallet.fullstack.cash
|
wallet.fullstack.cash
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
|
|
||||||
<li id='tor'>
|
<li id="tor">
|
||||||
<span>
|
<span>
|
||||||
<b>Tor</b>
|
<b>Tor</b>
|
||||||
</span>
|
</span>
|
||||||
<b>|</b>
|
<b>|</b>
|
||||||
<a href='http://puh2fyj2ly5b4p5m.onion/'>
|
<a href="http://2egutot63q765ciwsenlcy5zdyxwxt7olzbldr5dx5i3ixsef2nvrzid.onion/">
|
||||||
puh2fyj2ly5b4p5m.onion
|
2egutot63q765ciwsenlcy5zdyxwxt7olzbldr5dx5i3ixsef2nvrzid.onion
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
|
|
||||||
<li id='ipfs'>
|
<li id="ipfs">
|
||||||
<span>
|
<span>
|
||||||
<b>IPFS</b>
|
<b>IPFS</b>
|
||||||
</span>
|
</span>
|
||||||
@@ -179,32 +122,6 @@ class Footer extends React.Component {
|
|||||||
</div>
|
</div>
|
||||||
</Col>
|
</Col>
|
||||||
</Row>
|
</Row>
|
||||||
{/* <center>
|
|
||||||
<a href="https://psfoundation.cash/" target="_blank" rel="noreferrer">
|
|
||||||
Produced by the Permissionless Software Foundation
|
|
||||||
</a>
|
|
||||||
|
|
||||||
<br /><br />
|
|
||||||
<p>Ways to access this web-app:</p>
|
|
||||||
<ul>
|
|
||||||
<li>
|
|
||||||
Web: <a href="https://wallet.fullstack.cash">wallet.fullstack.cash</a>
|
|
||||||
</li>
|
|
||||||
|
|
||||||
<li>
|
|
||||||
Tor: <a href="http://puh2fyj2ly5b4p5m.onion/">puh2fyj2ly5b4p5m.onion</a>
|
|
||||||
</li>
|
|
||||||
|
|
||||||
<li>
|
|
||||||
IPFS: <a href="https://ipfs.io/ipfs/QmTMpYt66SGSjckXTHF6bPip6h1V5fXT23tEUJgy7pyTkf/">QmTMpYt66SGSjckXTHF6bPip6h1V5fXT23tEUJgy7pyTkf</a>
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
<br />
|
|
||||||
|
|
||||||
<a href="https://github.com/Permissionless-Software-Foundation/gatsby-ipfs-web-wallet" target="_blank" rel="noreferrer">
|
|
||||||
Source Code
|
|
||||||
</a>
|
|
||||||
</center> */}
|
|
||||||
</section>
|
</section>
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -8,7 +8,10 @@ const config = {
|
|||||||
titleShort: 'PSF',
|
titleShort: 'PSF',
|
||||||
balanceText: 'BCH Balance',
|
balanceText: 'BCH Balance',
|
||||||
balanceIcon: 'fab-bitcoin',
|
balanceIcon: 'fab-bitcoin',
|
||||||
memoAddr: 'bitcoincash:qr7u857krgsvq0dwe8rzlt5rcx35r6hnmu6glavtx0'
|
|
||||||
|
// The BCH address used in a memo.cash account. Used for tracking the IPFS
|
||||||
|
// hash of the mirror of this site.
|
||||||
|
memoAddr: 'bitcoincash:qqwdv3hkmvd5vk0uhwqrqnef54542e5ctvy3ppt0nq'
|
||||||
}
|
}
|
||||||
|
|
||||||
module.exports = config
|
module.exports = config
|
||||||
|
|||||||
Reference in New Issue
Block a user