@ -0,0 +1,32 @@ |
|||
import { FIAT_RATES } from '../storeType'; |
|||
import { triggerToaster } from '../actionCreators'; |
|||
import Config from '../../config'; |
|||
|
|||
export function fiatRates() { |
|||
return dispatch => { |
|||
return fetch(`http://46.20.235.46:8111/api/rates/kmd`, { |
|||
method: 'GET', |
|||
}) |
|||
.catch((error) => { |
|||
console.log(error); |
|||
dispatch( |
|||
triggerToaster( |
|||
'fiatRates', |
|||
'Error', |
|||
'error' |
|||
) |
|||
); |
|||
}) |
|||
.then(response => response.json()) |
|||
.then(json => { |
|||
dispatch(fiatRates(json)); |
|||
}); |
|||
} |
|||
} |
|||
|
|||
function fiatRates(json) { |
|||
return { |
|||
type: FIAT_RATES, |
|||
response: json, |
|||
} |
|||
} |
Before Width: | Height: | Size: 15 KiB |
Before Width: | Height: | Size: 5.3 KiB |
After Width: | Height: | Size: 4.3 KiB |
After Width: | Height: | Size: 3.9 KiB |
Before Width: | Height: | Size: 7.2 KiB |
After Width: | Height: | Size: 4.1 KiB |
Before Width: | Height: | Size: 11 KiB After Width: | Height: | Size: 19 KiB |
Before Width: | Height: | Size: 3.5 KiB |
Before Width: | Height: | Size: 5.6 KiB |
Before Width: | Height: | Size: 548 B |
Before Width: | Height: | Size: 5.3 KiB |
Before Width: | Height: | Size: 1.1 KiB |
Before Width: | Height: | Size: 3.0 KiB |
Before Width: | Height: | Size: 3.6 KiB |
Before Width: | Height: | Size: 13 KiB After Width: | Height: | Size: 20 KiB |
Before Width: | Height: | Size: 7.0 KiB |
Before Width: | Height: | Size: 4.1 KiB |
Before Width: | Height: | Size: 4.6 KiB |
@ -0,0 +1,45 @@ |
|||
.receive-address-context-menu, |
|||
.coin-tile-context-menu { |
|||
box-shadow: 0 1px 2px 1px rgba(0, 0, 0, 0.4); |
|||
background: #fff; |
|||
position: absolute; |
|||
z-index: 100; |
|||
margin-left: 65px; |
|||
margin-top: 5px; |
|||
|
|||
ul { |
|||
margin: 0; |
|||
list-style: none; |
|||
-webkit-margin-before: 0; |
|||
-webkit-margin-after: 0; |
|||
-webkit-margin-start: 0; |
|||
-webkit-margin-end: 0; |
|||
-webkit-padding-start: 0; |
|||
|
|||
li { |
|||
padding: 5px 15px; |
|||
|
|||
&:first-child { |
|||
margin-top: 5px; |
|||
} |
|||
&:last-child { |
|||
margin-bottom: 5px; |
|||
} |
|||
&:hover { |
|||
background: #f9f9f9; |
|||
cursor: pointer; |
|||
} |
|||
} |
|||
} |
|||
&.closed { |
|||
z-index: 1700; |
|||
position: absolute; |
|||
top: -100%; |
|||
left: -100%; |
|||
} |
|||
.receive-address-context-menu-get-qr { |
|||
.modal { |
|||
cursor: default; |
|||
} |
|||
} |
|||
} |
@ -0,0 +1,59 @@ |
|||
.coind-stop-icon, |
|||
.coind-remove-icon { |
|||
font-size: 20px; |
|||
position: absolute; |
|||
top: 19px; |
|||
right: 12px; |
|||
color: #ccc !important; |
|||
|
|||
&:hover { |
|||
color: #e9595b !important; |
|||
} |
|||
} |
|||
|
|||
.coind-remove-icon { |
|||
transform: rotate(45deg); |
|||
top: 45px; |
|||
} |
|||
|
|||
.coind-remove-icon-spv { |
|||
top: 19px; |
|||
} |
|||
|
|||
.icon-spv-connection-warning, |
|||
.icon-native-connection-warning { |
|||
position: absolute; |
|||
bottom: 20px; |
|||
right: 15px; |
|||
|
|||
&:before { |
|||
color: #f2a654; |
|||
font-size: 18px; |
|||
} |
|||
} |
|||
|
|||
.icon-native-connection-warning { |
|||
&:before { |
|||
color: #e9595b; |
|||
} |
|||
} |
|||
|
|||
.badge.up { |
|||
position: relative; |
|||
z-index: 10; |
|||
top: 0; |
|||
left: 0; |
|||
margin: 0; |
|||
border-radius: 0; |
|||
} |
|||
|
|||
.list-group-item { |
|||
.widget, |
|||
.widget-content { |
|||
height: 150px; |
|||
|
|||
.avatar { |
|||
margin-top: 10px; |
|||
} |
|||
} |
|||
} |
@ -0,0 +1,60 @@ |
|||
.navbar-fixed-bottom, |
|||
.navbar-fixed-top { |
|||
z-index: 100; |
|||
} |
|||
|
|||
.navbar { |
|||
&.navbar-fixed-top { |
|||
.dropdown { |
|||
&.open { |
|||
.dropdown-menu { |
|||
right: 0; |
|||
} |
|||
} |
|||
.dropdown-menu { |
|||
display: block; |
|||
right: -165px; |
|||
} |
|||
} |
|||
} |
|||
.offline { |
|||
margin-top: 22px; |
|||
|
|||
.offline-icon { |
|||
display: inline-block; |
|||
width: 10px; |
|||
height: 10px; |
|||
background: #f96868; |
|||
border-radius: 50%; |
|||
margin-left: 20px; |
|||
} |
|||
} |
|||
} |
|||
|
|||
.navbar-nav > li > a.navbar-avatar, |
|||
.navbar-toolbar > li > a.navbar-avatar { |
|||
&.dropdown-toggle { |
|||
font-size: 24px; |
|||
padding-top: 24px; |
|||
|
|||
i { |
|||
position: relative; |
|||
top: -2px; |
|||
} |
|||
} |
|||
} |
|||
|
|||
.coind-actions-menu { |
|||
position: absolute; |
|||
top: 22px; |
|||
left: 20px; |
|||
} |
|||
|
|||
.coin-tile-context-menu { |
|||
top: 45px; |
|||
left: -34px; |
|||
|
|||
li { |
|||
color: #757575; |
|||
} |
|||
} |
@ -0,0 +1,9 @@ |
|||
.send-coin-sync-warning { |
|||
.icon { |
|||
font-size: 18px; |
|||
} |
|||
.desc { |
|||
position: relative; |
|||
top: -2px; |
|||
} |
|||
} |
@ -1,179 +0,0 @@ |
|||
import React from 'react'; |
|||
import { translate } from '../../../translate/translate'; |
|||
import { connect } from 'react-redux'; |
|||
|
|||
import { |
|||
addPeerNode, |
|||
getPeersList, |
|||
getPeersListState, |
|||
} from '../../../actions/actionCreators'; |
|||
import Store from '../../../store'; |
|||
|
|||
import AddCoinOptionsCrypto from '../../addcoin/addcoinOptionsCrypto'; |
|||
import AddCoinOptionsAC from '../../addcoin/addcoinOptionsAC'; |
|||
import AddCoinOptionsACFiat from '../../addcoin/addcoinOptionsACFiat'; |
|||
|
|||
class AddNodePanel extends React.Component { |
|||
constructor() { |
|||
super(); |
|||
this.state = { |
|||
addNodeCoin: null, |
|||
addPeerIP: null, |
|||
getPeersCoin: null, |
|||
trimPassphraseTimer: null, |
|||
wifkeysPassphrase:'', |
|||
}; |
|||
this.renderSNPeersList = this.renderSNPeersList.bind(this); |
|||
this.renderPeersList = this.renderPeersList.bind(this); |
|||
this.checkNodes = this.checkNodes.bind(this); |
|||
this.addNode = this.addNode.bind(this); |
|||
this.updateInput = this.updateInput.bind(this); |
|||
} |
|||
|
|||
renderSNPeersList() { |
|||
if (this.state.getPeersCoin) { |
|||
const _getPeersCoin = this.state.getPeersCoin; |
|||
const _supernetPeers = this.props.Settings.supernetPeers; |
|||
const coin = _getPeersCoin.split('|')[0]; |
|||
|
|||
if (_supernetPeers && |
|||
_getPeersCoin && |
|||
_supernetPeers[coin]) { |
|||
return _supernetPeers[coin].map((ip) => |
|||
<div key={ ip }>{ ip }</div> |
|||
); |
|||
} else { |
|||
return null; |
|||
} |
|||
} else { |
|||
return null; |
|||
} |
|||
} |
|||
|
|||
renderPeersList() { |
|||
if (this.state.getPeersCoin) { |
|||
const _getPeersCoin = this.state.getPeersCoin; |
|||
const _rawPeers = this.props.Settings.rawPeers; |
|||
const coin = _getPeersCoin.split('|')[0]; |
|||
|
|||
if (_rawPeers && |
|||
_getPeersCoin && |
|||
_rawPeers[coin]) { |
|||
return _rawPeers[coin].map((ip) => |
|||
<div key={ ip }>{ ip }</div> |
|||
); |
|||
} else { |
|||
return null; |
|||
} |
|||
} else { |
|||
return null; |
|||
} |
|||
} |
|||
|
|||
checkNodes() { |
|||
if (this.state.getPeersCoin) { |
|||
console.warn(this.state.getPeersCoin.split('|')[0]); |
|||
Store.dispatch(getPeersList(this.state.getPeersCoin.split('|')[0])); |
|||
} |
|||
} |
|||
|
|||
addNode() { |
|||
if (this.state.addNodeCoin && |
|||
this.state.addPeerIP) { |
|||
Store.dispatch( |
|||
addPeerNode( |
|||
this.state.addNodeCoin.split('|')[0], |
|||
this.state.addPeerIP |
|||
) |
|||
); |
|||
} |
|||
} |
|||
|
|||
updateInput(e) { |
|||
this.setState({ |
|||
[e.target.name]: e.target.value, |
|||
}); |
|||
} |
|||
|
|||
render() { |
|||
return ( |
|||
<div className="row"> |
|||
<div className="col-sm-6"> |
|||
<div className="col-sm-12"> |
|||
<p>{ translate('INDEX.USE_THIS_SECTION') }</p> |
|||
</div> |
|||
<div className="col-sm-8 col-xs-12"> |
|||
<div className="form-group"> |
|||
<select |
|||
className="form-control form-material" |
|||
name="getPeersCoin" |
|||
onChange={ this.updateInput }> |
|||
<option>{ translate('INDEX.SELECT_COIN') }</option> |
|||
<AddCoinOptionsCrypto /> |
|||
<AddCoinOptionsAC /> |
|||
<AddCoinOptionsACFiat /> |
|||
</select> |
|||
</div> |
|||
</div> |
|||
<div className="col-sm-4 col-xs-12 text-align-center"> |
|||
<button |
|||
type="button" |
|||
className="btn btn-primary waves-effect waves-light" |
|||
onClick={ this.checkNodes }>{ translate('INDEX.CHECK_NODES') }</button> |
|||
</div> |
|||
<div className="col-sm-12"> |
|||
<h5> |
|||
SuperNET Peers: |
|||
</h5> |
|||
<div>{ this.renderSNPeersList() }</div> |
|||
<h5> |
|||
Raw Peers: |
|||
</h5> |
|||
<div>{ this.renderPeersList() }</div> |
|||
</div> |
|||
</div> |
|||
|
|||
<div className="col-sm-6"> |
|||
<div className="col-sm-12"> |
|||
<p>{ translate('INDEX.USE_THIS_SECTION_PEER') }</p> |
|||
</div> |
|||
<div className="col-sm-8 col-xs-12"> |
|||
<div className="form-group"> |
|||
<select |
|||
className="form-control form-material" |
|||
name="addNodeCoin" |
|||
onChange={ this.updateInput }> |
|||
<option>{ translate('INDEX.SELECT_COIN') }</option> |
|||
<AddCoinOptionsCrypto /> |
|||
<AddCoinOptionsAC /> |
|||
<AddCoinOptionsACFiat /> |
|||
</select> |
|||
</div> |
|||
<div className="form-group"> |
|||
<input |
|||
type="text" |
|||
className="form-control" |
|||
name="addPeerIP" |
|||
placeholder={ translate('SETTINGS.ADD_PEER_IP') } |
|||
onChange={ this.updateInput } /> |
|||
</div> |
|||
</div> |
|||
<div className="col-sm-4 col-xs-12 text-align-center"> |
|||
<button |
|||
type="button" |
|||
className="btn btn-primary waves-effect waves-light" |
|||
onClick={ this.addNode }>{ translate('INDEX.ADD_NODE') }</button> |
|||
</div> |
|||
</div> |
|||
</div> |
|||
); |
|||
}; |
|||
} |
|||
|
|||
const mapStateToProps = (state) => { |
|||
return { |
|||
Settings: state.Settings, |
|||
}; |
|||
}; |
|||
|
|||
export default connect(mapStateToProps)(AddNodePanel); |
@ -0,0 +1,21 @@ |
|||
.col-lg-12 { |
|||
&.col-xs-12 { |
|||
&.balance-placeholder--bold { |
|||
.icon { |
|||
&.fa-eye { |
|||
position: relative; |
|||
top: -2px; |
|||
padding-right: 5px; |
|||
} |
|||
} |
|||
} |
|||
} |
|||
} |
|||
|
|||
.balance-placeholder--bold { |
|||
.pull-left { |
|||
font-weight: 500; |
|||
font-size: 16px; |
|||
padding-top: 16px !important; |
|||
} |
|||
} |
@ -0,0 +1,4 @@ |
|||
.header-easydex { |
|||
background-repeat: no-repeat; |
|||
background-position: 0; |
|||
} |
@ -0,0 +1,3 @@ |
|||
.bg--white { |
|||
background: #fff; |
|||
} |
@ -0,0 +1,62 @@ |
|||
.breadcrumb { |
|||
padding: 8px 30px 0; |
|||
position: relative; |
|||
top: -10px; |
|||
} |
|||
|
|||
.header-easydex-section { |
|||
img { |
|||
max-width: 60px; |
|||
} |
|||
} |
|||
|
|||
.coin-logo-wide { |
|||
padding: 8px 30px 0; |
|||
position: relative; |
|||
top: 0; |
|||
|
|||
.header-easydex-section { |
|||
img { |
|||
width: inherit; |
|||
max-width: inherit; |
|||
position: relative; |
|||
top: -5px; |
|||
} |
|||
} |
|||
|
|||
&.native-coin-logo { |
|||
top: -93px; |
|||
|
|||
.header-easydex-section { |
|||
img { |
|||
width: inherit; |
|||
} |
|||
} |
|||
} |
|||
} |
|||
|
|||
.native-coin-logo { |
|||
float: left; |
|||
position: absolute; |
|||
top: -105px; |
|||
z-index: 100; |
|||
|
|||
.header-easydex-section { |
|||
img { |
|||
width: 60px; |
|||
max-height: 60px; |
|||
} |
|||
} |
|||
} |
|||
|
|||
.page-header--native { |
|||
height: 75px; |
|||
} |
|||
|
|||
.page-header--spv { |
|||
height: 120px; |
|||
|
|||
.page-header-actions { |
|||
top: 73%; |
|||
} |
|||
} |
@ -0,0 +1,21 @@ |
|||
@media only screen and (min-width : 1201px) { |
|||
.wallet-widgets { |
|||
.flex { |
|||
display: flex; |
|||
flex-wrap: wrap; |
|||
} |
|||
> div { |
|||
display: flex; |
|||
|
|||
.widget, |
|||
.widget-content { |
|||
height: 100%; |
|||
|
|||
> div, |
|||
.clearfix { |
|||
height: 100%; |
|||
} |
|||
} |
|||
} |
|||
} |
|||
} |
@ -0,0 +1,65 @@ |
|||
.switch { |
|||
position: relative; |
|||
display: inline-block; |
|||
width: 40px; |
|||
height: 24px; |
|||
|
|||
input { |
|||
display: none; |
|||
} |
|||
} |
|||
|
|||
.slider { |
|||
border-radius: 20px; |
|||
position: absolute; |
|||
cursor: pointer; |
|||
top: 0; |
|||
left: 0; |
|||
right: 0; |
|||
bottom: 0; |
|||
background-color: #ccc; |
|||
-webkit-transition: .4s; |
|||
transition: .4s; |
|||
|
|||
&.round { |
|||
border-radius: 34px; |
|||
|
|||
&:before { |
|||
border-radius: 50%; |
|||
} |
|||
} |
|||
&:before { |
|||
border-radius: 50%; |
|||
position: absolute; |
|||
content: ''; |
|||
height: 20px; |
|||
width: 20px; |
|||
left: 2px; |
|||
bottom: 2px; |
|||
background-color: white; |
|||
-webkit-transition: .4s; |
|||
transition: .4s; |
|||
} |
|||
} |
|||
|
|||
.toggle-label { |
|||
color: #757575; |
|||
display: inline-block; |
|||
position: relative; |
|||
top: -12px; |
|||
left: 8px; |
|||
} |
|||
|
|||
input:checked + .slider { |
|||
background-color: rgb(57, 73, 171); |
|||
} |
|||
|
|||
input:focus + .slider { |
|||
box-shadow: 0 0 1px rgb(57, 73, 171); |
|||
} |
|||
|
|||
input:checked + .slider:before { |
|||
-webkit-transform: translateX(16px); |
|||
-ms-transform: translateX(16px); |
|||
transform: translateX(16px); |
|||
} |