Skip to content
This repository was archived by the owner on Mar 16, 2022. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion src/bootstrap/app.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,14 +13,15 @@ import PageNotFound from '../containers/page-not-found'

import Initializer from './initializer'
import GlobalComponents from './global-components'
import { ETHAddressRegExp, ETHAddressRegExpCaptureGroup } from './dapp-api'
import { ETHAddressRegExpCaptureGroup, ETHAddressRegExp } from './dapp-api'

import './app.css'

const toWithAddress = base => location =>
`${base}/${location.pathname.match(ETHAddressRegExp)[0]}`
const hasNonRootAddress = location =>
location.pathname.slice(0, 3) !== '/0x' &&
location.pathname.slice(0, 4) !== '/404' &&
ETHAddressRegExp.test(location.pathname)
const ConnectedNavBar = connect(state => ({
accounts: state.wallet.accounts,
Expand All @@ -31,6 +32,11 @@ const ConnectedNavBar = connect(state => ({
accounts={accounts}
balance={balance}
routes={[
{
name: 'Home',
to: '/',
visible: location => location.pathname.slice(0, 4) === '/404'
},
{
name: 'Simple',
to: toWithAddress('/simple'),
Expand Down
4 changes: 2 additions & 2 deletions src/bootstrap/dapp-api.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,14 +14,14 @@ else eth = new Eth(new Eth.HttpProvider(ETHEREUM_PROVIDER))

const IICOContractFactory = eth.contract && eth.contract(IICO.abi) // TODO: Put this on NPM or load dynamically?

const ETHAddressRegExp = /0x[a-fA-F0-9]{40}/
const ETHAddressRegExpCaptureGroup = '(0x[a-fA-F0-9]{40})'
const ETHAddressRegExp = /0x[a-fA-F0-9]{40}/
const strictETHAddressRegExp = /^0x[a-fA-F0-9]{40}$/

export {
eth,
IICOContractFactory,
ETHAddressRegExp,
ETHAddressRegExpCaptureGroup,
ETHAddressRegExp,
strictETHAddressRegExp
}
21 changes: 20 additions & 1 deletion src/containers/iico/components/bids/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -192,6 +192,8 @@ class Bids extends PureComponent {
<div className="Bids-confirm">
Are you sure you wish to withdraw this bid?
<br />
<b>This withdraws your ETH, it does not redeem tokens.</b>
<br />
<ChainNumber>{lockedIn}</ChainNumber> ETH
<br />
would remain locked in{lockedIn ? (
Expand Down Expand Up @@ -281,14 +283,26 @@ class Bids extends PureComponent {
KYCLevel = 'None'
}

let KYCLink
if (process.env.REACT_APP_BRANCH === 'master')
KYCLink = (
<a
href="https://kleros.io/kyc"
rel="noopener noreferrer"
target="_blank"
>
{KYCLevel}
</a>
)

return (
<div id="joyridePlaceBid" className="Bids">
<h1>Your Bids</h1>
{!tutorialNow && (
<StatRow>
<StatBlock
label="KYC Level"
value={KYCLevel}
value={KYCLink || KYCLevel}
tooltip={KYCLevelTooltip}
/>
{KYCLevel === 'Base' && (
Expand Down Expand Up @@ -513,6 +527,11 @@ class Bids extends PureComponent {
)}
</Button>
}
tooltip={
canWithdraw
? 'This withdraws your ETH, it does not redeem tokens.'
: 'This redeems your tokens.'
}
noFlex
/>
)}
Expand Down
2 changes: 1 addition & 1 deletion src/containers/simple-bid/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ class SimpleBid extends PureComponent {
>
KYC
</a>{' '}
and you need to send at least 300,000 gas with the transaction.
and you need to <b>send at least 300,000 gas with the transaction.</b>
<RenderIf
resource={IICOData}
loading={null}
Expand Down