Compare commits
25 Commits
Author | SHA1 | Date |
---|---|---|
Josh Cincinnati | 5aaa096338 | |
André Neves | b07692bf51 | |
Andre Neves | 96f2de6b58 | |
André Neves | 52f248675f | |
Aditya Kulkarni | f7bfec6333 | |
André Neves | e3a6dd5a69 | |
Andre Neves | 5d74a8e567 | |
Andre Neves | ec782c374e | |
André Neves | e1927bc878 | |
Andre Neves | 4e720d55cb | |
Andre Neves | edf3060d78 | |
Andre Neves | 2bdfdb6742 | |
Andre Neves | 7c6bda8c73 | |
André Neves | 9ce6751fe8 | |
André Neves | 1bc8a2852f | |
George Lima | bf650e19dd | |
George Lima | 228c2b1c5a | |
Marius Kjærstad | 01b32b48f6 | |
Andre Neves | 64dadb9823 | |
André Neves | e5175fd742 | |
Andre Neves | 8641331e6b | |
George Lima | e20d35eb67 | |
George Lima | 5019907bf3 | |
George Lima | 55d55508b4 | |
Andre Neves | 5c114d21ad |
|
@ -1,6 +1,6 @@
|
|||
---
|
||||
name: Question 🤔
|
||||
about: Usage question or discussion about Gatsby.
|
||||
about: Usage question or discussion about Zepio.
|
||||
---
|
||||
|
||||
## Summary
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
# Zepio | ZEC Wallet
|
||||
## ZEPIO IS NO LONGER ACTIVELY MAINTAINED
|
||||
*We will be archiving this repo soon. If you would like a shielded-first desktop wallet, we recommend [ZecWallet](https://www.zecwallet.co/).*
|
||||
|
||||
Zepio is a Sapling-enabled shielded-address-first Zcash wallet, featuring cross-platform applications (macOS, Windows and Linux), built-in full node with support for `mainnet` and `testnet`, as well as `dark` and `light` themes.
|
||||
|
||||
|
@ -123,4 +124,4 @@ In order to contribute and submit PRs to improve the **Zepio** codebase, please
|
|||
|
||||
## License
|
||||
|
||||
MIT © Zcash Foundation 2019 [zfnd.org](zfnd.org)
|
||||
MIT © Zcash Foundation 2019 [zfnd.org](https://zfnd.org)
|
||||
|
|
|
@ -1,16 +1,18 @@
|
|||
// @flow
|
||||
|
||||
import React, { PureComponent, Fragment } from 'react';
|
||||
// eslint-disable-next-line import/no-extraneous-dependencies
|
||||
import { ipcRenderer } from 'electron';
|
||||
import styled, { withTheme } from 'styled-components';
|
||||
import uuid from 'uuid/v4';
|
||||
import eres from 'eres';
|
||||
import humanizeDuration from 'humanize-duration';
|
||||
|
||||
import { TextComponent } from '../components/text';
|
||||
|
||||
import ConsoleSymbolDark from '../assets/images/console_zcash_dark.png';
|
||||
import ConsoleSymbolLight from '../assets/images/console_zcash_light.png';
|
||||
import { DARK } from '../constants/themes';
|
||||
import rpc from '../../services/api';
|
||||
import store from '../../config/electron-store';
|
||||
|
||||
const Wrapper = styled.div`
|
||||
max-height: 100%;
|
||||
|
@ -31,30 +33,6 @@ const ConsoleImg = styled.img`
|
|||
width: auto;
|
||||
`;
|
||||
|
||||
const initialLog = `
|
||||
Thank you for running a Zcash node!
|
||||
You're helping to strengthen the network and contributing to a social good :)
|
||||
|
||||
In order to ensure you are adequately protecting your privacy when using Zcash, please see <https://z.cash/support/security/>.
|
||||
`;
|
||||
|
||||
const defaultState = `
|
||||
Thank you for running a Zcash node!
|
||||
You're helping to strengthen the network and contributing to a social good :)
|
||||
In order to ensure you are adequately protecting your privacy when using Zcash, please see <https://z.cash/support/security/>.
|
||||
|
||||
Block height | 0
|
||||
Connections | 0
|
||||
Network solution rate | 0 Sol/s
|
||||
You are currently not mining.
|
||||
To enable mining, add 'gen=1' to your zcash.conf and restart.
|
||||
|
||||
Since starting this node 0 minutes, 0 seconds ago:
|
||||
- You have validated 0 transactions!
|
||||
\n
|
||||
------------------------------------------
|
||||
`;
|
||||
|
||||
const breakpoints = [1, 4, 7, 10, 13];
|
||||
|
||||
type Props = {
|
||||
|
@ -62,26 +40,68 @@ type Props = {
|
|||
};
|
||||
|
||||
type State = {
|
||||
log: string,
|
||||
blockHeight: number,
|
||||
connections: number,
|
||||
networkSolutionsRate: number,
|
||||
};
|
||||
|
||||
class Component extends PureComponent<Props, State> {
|
||||
interval: ?IntervalID = null;
|
||||
|
||||
requestOnTheFly: boolean = false;
|
||||
|
||||
state = {
|
||||
log: defaultState,
|
||||
blockHeight: 0,
|
||||
connections: 0,
|
||||
networkSolutionsRate: 0,
|
||||
};
|
||||
|
||||
componentDidMount() {
|
||||
ipcRenderer.on('zcashd-log', (event: empty, message: string) => {
|
||||
this.setState(() => ({ log: initialLog + message }));
|
||||
});
|
||||
this.interval = setInterval(() => this.update(), 3000);
|
||||
}
|
||||
|
||||
componentWillUnmount() {
|
||||
ipcRenderer.removeAllListeners('zcashd-log');
|
||||
clearInterval(this.interval);
|
||||
}
|
||||
|
||||
update = async () => {
|
||||
if (this.requestOnTheFly) return;
|
||||
|
||||
this.requestOnTheFly = true;
|
||||
|
||||
const [err, result] = await eres(Promise.all([rpc.getinfo(), rpc.getmininginfo()]));
|
||||
|
||||
if (err) return;
|
||||
|
||||
this.setState(
|
||||
{
|
||||
blockHeight: result[0].blocks,
|
||||
connections: result[0].connections,
|
||||
networkSolutionsRate: result[1].networksolps,
|
||||
},
|
||||
() => {
|
||||
this.requestOnTheFly = false;
|
||||
},
|
||||
);
|
||||
};
|
||||
|
||||
getLog = (state: State) => `
|
||||
Thank you for running a Zcash node!
|
||||
You're helping to strengthen the network and contributing to a social good :)
|
||||
In order to ensure you are adequately protecting your privacy when using Zcash, please see <https://z.cash/support/security/>.
|
||||
|
||||
Block height | ${state.blockHeight}
|
||||
Connections | ${state.connections}
|
||||
Network solution rate | ${state.networkSolutionsRate} Sol/s
|
||||
|
||||
Started ${humanizeDuration(new Date() - new Date(store.get('DAEMON_START_TIME')), {
|
||||
round: true,
|
||||
})} ago
|
||||
\n
|
||||
------------------------------------------
|
||||
`;
|
||||
|
||||
render() {
|
||||
const { log } = this.state;
|
||||
const { theme } = this.props;
|
||||
|
||||
const ConsoleSymbol = theme.mode === DARK ? ConsoleSymbolDark : ConsoleSymbolLight;
|
||||
|
@ -90,12 +110,14 @@ class Component extends PureComponent<Props, State> {
|
|||
<Wrapper id='console-wrapper'>
|
||||
<Fragment>
|
||||
<ConsoleImg src={ConsoleSymbol} alt='Zcashd' />
|
||||
{log.split('\n').map((item, idx) => (
|
||||
<Fragment key={uuid()}>
|
||||
<ConsoleText value={item} />
|
||||
{breakpoints.includes(idx) ? <br /> : null}
|
||||
</Fragment>
|
||||
))}
|
||||
{this.getLog(this.state)
|
||||
.split('\n')
|
||||
.map((item, idx) => (
|
||||
<Fragment key={uuid()}>
|
||||
<ConsoleText value={item} />
|
||||
{breakpoints.includes(idx) ? <br /> : null}
|
||||
</Fragment>
|
||||
))}
|
||||
</Fragment>
|
||||
</Wrapper>
|
||||
);
|
||||
|
|
|
@ -26,6 +26,8 @@ import { formatNumber } from '../utils/format-number';
|
|||
import { ascii2hex } from '../utils/ascii-to-hexadecimal';
|
||||
import { isHex } from '../utils/is-hex';
|
||||
import { getCoinName } from '../utils/get-coin-name';
|
||||
import { openExternal } from '../utils/open-external';
|
||||
import { ZCASH_EXPLORER_BASE_URL } from '../constants/explorer';
|
||||
|
||||
import SentIcon from '../assets/images/transaction_sent_icon_dark.svg';
|
||||
import MenuIconDark from '../assets/images/menu_icon_dark.svg';
|
||||
|
@ -387,6 +389,11 @@ const ZSuccessMessage = styled(TextComponent)`
|
|||
const ZSuccessTransactionId = styled(TextComponent)`
|
||||
text-align: center;
|
||||
word-break: break-all !important;
|
||||
|
||||
&:hover {
|
||||
cursor: pointer;
|
||||
text-decoration: underline;
|
||||
}
|
||||
`;
|
||||
|
||||
const CustomFeeWarning = styled(TextComponent)`
|
||||
|
@ -634,7 +641,7 @@ class Component extends PureComponent<Props, State> {
|
|||
<ZSuccessLabel value='Success!' />
|
||||
<ZSuccessContentWrapper>
|
||||
<ZSuccessMessage value='Your transaction was sent successfully.' />
|
||||
<ZSuccessTransactionId value={`Transaction ID: ${operationId}`} />
|
||||
<ZSuccessTransactionId value={`Transaction ID: ${operationId}`} onClick={() => openExternal(ZCASH_EXPLORER_BASE_URL + operationId)} />
|
||||
</ZSuccessContentWrapper>
|
||||
<FormButton
|
||||
label='Done'
|
||||
|
|
BIN
bin/linux/zcashd
BIN
bin/linux/zcashd
Binary file not shown.
BIN
bin/mac/zcashd
BIN
bin/mac/zcashd
Binary file not shown.
Binary file not shown.
|
@ -65,6 +65,7 @@ let resolved = false;
|
|||
|
||||
const ZCASHD_PROCESS_NAME = getDaemonName();
|
||||
const DAEMON_PROCESS_PID = 'DAEMON_PROCESS_PID';
|
||||
const DAEMON_START_TIME = 'DAEMON_START_TIME';
|
||||
|
||||
let isWindowOpened = false;
|
||||
|
||||
|
@ -95,6 +96,7 @@ const runDaemon: () => Promise<?ChildProcess> = () => new Promise(async (resolve
|
|||
store.delete('rpcconnect');
|
||||
store.delete('rpcport');
|
||||
store.delete(DAEMON_PROCESS_PID);
|
||||
store.delete(DAEMON_START_TIME);
|
||||
|
||||
const processName = path.join(getBinariesPath(), getOsFolder(), ZCASHD_PROCESS_NAME);
|
||||
const isRelaunch = Boolean(process.argv.find(arg => arg === '--relaunch'));
|
||||
|
@ -223,8 +225,8 @@ const runDaemon: () => Promise<?ChildProcess> = () => new Promise(async (resolve
|
|||
store.set(DAEMON_PROCESS_PID, childProcess.pid);
|
||||
|
||||
childProcess.stdout.on('data', (data) => {
|
||||
sendToRenderer('zcashd-log', data.toString(), false);
|
||||
if (!resolved) {
|
||||
store.set(DAEMON_START_TIME, Date.now());
|
||||
resolve(childProcess);
|
||||
resolved = true;
|
||||
}
|
||||
|
|
|
@ -0,0 +1,22 @@
|
|||
declare module 'humanize-duration' {
|
||||
declare type options = {
|
||||
language?: string,
|
||||
fallbacks?: string[],
|
||||
delimiter?: string,
|
||||
spacer?: string,
|
||||
largest?: number,
|
||||
units?: string[],
|
||||
round?: boolean,
|
||||
decimal?: string,
|
||||
conjunction?: string,
|
||||
maxDecimalPoints?: number,
|
||||
unitMeasures?: {
|
||||
y?: number,
|
||||
mo?: number,
|
||||
w?: number,
|
||||
d?: number,
|
||||
},
|
||||
};
|
||||
|
||||
declare module.exports: (milli: number, opt?: options) => string;
|
||||
}
|
|
@ -1,7 +1,7 @@
|
|||
{
|
||||
"name": "zepio",
|
||||
"productName": "Zepio",
|
||||
"version": "0.7.3",
|
||||
"version": "0.9.0",
|
||||
"description": "Zepio | Cross-platform sapling-enabled full-node Zcash wallet",
|
||||
"main": "config/main.js",
|
||||
"homepage": "https://zepiowallet.com",
|
||||
|
@ -230,6 +230,7 @@
|
|||
"find-process": "^1.2.1",
|
||||
"got": "^9.6.0",
|
||||
"history": "^4.7.2",
|
||||
"humanize-duration": "^3.18.0",
|
||||
"lodash.flow": "^3.5.0",
|
||||
"lodash.groupby": "^4.6.0",
|
||||
"lodash.uniqby": "^4.7.0",
|
||||
|
|
|
@ -1 +1 @@
|
|||
<svg xmlns="http://www.w3.org/2000/svg" width="88" height="20"><linearGradient id="b" x2="0" y2="100%"><stop offset="0" stop-color="#bbb" stop-opacity=".1"/><stop offset="1" stop-opacity=".1"/></linearGradient><mask id="a"><rect width="88" height="20" rx="3" fill="#fff"/></mask><g mask="url(#a)"><path fill="#555" d="M0 0h34v20H0z"/><path fill="#4C1" d="M34 0h54v20H34z"/><path fill="url(#b)" d="M0 0h88v20H0z"/></g><g fill="#fff" text-anchor="middle" font-family="Verdana,DejaVu Sans,Geneva,sans-serif" font-size="11"><text x="17" y="15" fill="#010101" fill-opacity=".3">flow</text><text x="17" y="14">flow</text><text x="60" y="15" fill="#010101" fill-opacity=".3">passing</text><text x="60" y="14">passing</text></g></svg>
|
||||
<svg xmlns="http://www.w3.org/2000/svg" width="81" height="20"><linearGradient id="b" x2="0" y2="100%"><stop offset="0" stop-color="#bbb" stop-opacity=".1"/><stop offset="1" stop-opacity=".1"/></linearGradient><mask id="a"><rect width="81" height="20" rx="3" fill="#fff"/></mask><g mask="url(#a)"><path fill="#555" d="M0 0h34v20H0z"/><path fill="#E05D44" d="M34 0h47v20H34z"/><path fill="url(#b)" d="M0 0h81v20H0z"/></g><g fill="#fff" text-anchor="middle" font-family="Verdana,DejaVu Sans,Geneva,sans-serif" font-size="11"><text x="17" y="15" fill="#010101" fill-opacity=".3">flow</text><text x="17" y="14">flow</text><text x="56.5" y="15" fill="#010101" fill-opacity=".3">failing</text><text x="56.5" y="14">failing</text></g></svg>
|
Before Width: | Height: | Size: 726 B After Width: | Height: | Size: 733 B |
|
@ -1 +1 @@
|
|||
<svg xmlns="http://www.w3.org/2000/svg" width="125" height="20"><linearGradient id="b" x2="0" y2="100%"><stop offset="0" stop-color="#bbb" stop-opacity=".1"/><stop offset="1" stop-opacity=".1"/></linearGradient><mask id="a"><rect width="125" height="20" rx="3" fill="#fff"/></mask><g mask="url(#a)"><path fill="#555" d="M0 0h91v20H0z"/><path fill="#4C1" d="M91 0h34v20H91z"/><path fill="url(#b)" d="M0 0h125v20H0z"/></g><g fill="#fff" text-anchor="middle" font-family="Verdana,DejaVu Sans,Geneva,sans-serif" font-size="11"><text x="45.5" y="15" fill="#010101" fill-opacity=".3">flow-coverage</text><text x="45.5" y="14">flow-coverage</text><text x="107" y="15" fill="#010101" fill-opacity=".3">88%</text><text x="107" y="14">88%</text></g></svg>
|
||||
<svg xmlns="http://www.w3.org/2000/svg" width="125" height="20"><linearGradient id="b" x2="0" y2="100%"><stop offset="0" stop-color="#bbb" stop-opacity=".1"/><stop offset="1" stop-opacity=".1"/></linearGradient><mask id="a"><rect width="125" height="20" rx="3" fill="#fff"/></mask><g mask="url(#a)"><path fill="#555" d="M0 0h91v20H0z"/><path fill="#4C1" d="M91 0h34v20H91z"/><path fill="url(#b)" d="M0 0h125v20H0z"/></g><g fill="#fff" text-anchor="middle" font-family="Verdana,DejaVu Sans,Geneva,sans-serif" font-size="11"><text x="45.5" y="15" fill="#010101" fill-opacity=".3">flow-coverage</text><text x="45.5" y="14">flow-coverage</text><text x="107" y="15" fill="#010101" fill-opacity=".3">89%</text><text x="107" y="14">89%</text></g></svg>
|
Before Width: | Height: | Size: 745 B After Width: | Height: | Size: 745 B |
|
@ -7887,6 +7887,11 @@ humanize-duration@^3.15.3:
|
|||
version "3.16.0"
|
||||
resolved "https://registry.yarnpkg.com/humanize-duration/-/humanize-duration-3.16.0.tgz#c7ec3b898305f007c63893f891870b2b5a2e0a7d"
|
||||
|
||||
humanize-duration@^3.18.0:
|
||||
version "3.18.0"
|
||||
resolved "https://registry.yarnpkg.com/humanize-duration/-/humanize-duration-3.18.0.tgz#ba07a945d6d4358b9751fecabe27864bf965afbc"
|
||||
integrity sha512-reYy4EJMqlhX13TDlgSqLYfVGKOoixoEzsSL6DBlp22dScWN8Q2eMgDF4L0q28mzbgO40rnBy3WyEUQEhfYALw==
|
||||
|
||||
humanize-string@^1.0.2:
|
||||
version "1.0.2"
|
||||
resolved "https://registry.yarnpkg.com/humanize-string/-/humanize-string-1.0.2.tgz#fef0a8bc9b1b857ca4013bbfaea75071736988f6"
|
||||
|
|
Loading…
Reference in New Issue