Skip to content

Commit

Permalink
Merge pull request #241 from eoscostarica/bugfix/ricardian-contract-url
Browse files Browse the repository at this point in the history
fix: hardcoded url
  • Loading branch information
xavier506 authored Oct 22, 2020
2 parents 6a17ed0 + 09b6982 commit 2722858
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 4 deletions.
7 changes: 6 additions & 1 deletion src/config/ual.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,5 +17,10 @@ export const ualConfig = {
host:
process.env.REACT_APP_EOS_API_HOST_FAILOVER || 'jungle.eosargentina.io',
port: parseInt(process.env.REACT_APP_EOS_API_PORT_FAILOVER || '443')
}
},
endpoint: `${process.env.REACT_APP_EOS_API_PROTOCOL}://${
process.env.REACT_APP_EOS_API_HOST
}${process.env.REACT_APP_EOS_API_PORT ? ':' : ''}${
process.env.REACT_APP_EOS_API_PORT
}`
}
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ import Tab from '@material-ui/core/Tab'
import AppBar from '@material-ui/core/AppBar'
import { RicardianContract } from '@eoscostarica/eoscr-components'

import { ualConfig } from '../../../../config'

const useStyles = makeStyles((theme) => ({
wrapper: {
overflow: 'hidden',
Expand Down Expand Up @@ -81,7 +83,7 @@ const TermsOfUse = ({ isMobile }) => {
value={tab}
onChange={(event, newValue) => setTab(newValue)}
classes={{ indicator: classes.selectorTab }}
variant={isMobile ? 'fullWidth' : ''}
variant={isMobile ? 'fullWidth' : 'standard'}
>
<Tab label="evolutiondex" />
<Tab label="wevotethefee" />
Expand All @@ -91,7 +93,7 @@ const TermsOfUse = ({ isMobile }) => {
<Box className={classes.wrapper}>
<RicardianContract
contractName="evolutiondex"
httpEndpoint="https://jungle.eosio.cr"
httpEndpoint={ualConfig.endpoint}
LinearProgressOverrideClasses={{
barColorPrimary: classes.overrideFrontLinearColor,
colorPrimary: classes.overrideLinearColor
Expand All @@ -104,7 +106,7 @@ const TermsOfUse = ({ isMobile }) => {
<Box className={classes.wrapper}>
<RicardianContract
contractName="wevotethefee"
httpEndpoint="https://jungle.eosio.cr"
httpEndpoint={ualConfig.endpoint}
LinearProgressOverrideClasses={{
barColorPrimary: classes.overrideFrontLinearColor,
colorPrimary: classes.overrideLinearColor
Expand Down

0 comments on commit 2722858

Please sign in to comment.