aboutsummaryrefslogtreecommitdiffstats
path: root/ui/app/first-time/disclaimer.js
diff options
context:
space:
mode:
authorFrankie <frankie.diamond@gmail.com>2016-10-12 07:19:13 +0800
committerGitHub <noreply@github.com>2016-10-12 07:19:13 +0800
commit229d95956bc36ec413533df00389f8c5127e050b (patch)
treeb97f0021958fbcf8ed93ac9c44e3d24eaf50f4e4 /ui/app/first-time/disclaimer.js
parent97970e803d55fc8a578a3a9e6d6f3ab19c332b4b (diff)
parentd67a5031c7f2b4cd14d3d27f3769a31769012f54 (diff)
downloadtangerine-wallet-browser-229d95956bc36ec413533df00389f8c5127e050b.tar
tangerine-wallet-browser-229d95956bc36ec413533df00389f8c5127e050b.tar.gz
tangerine-wallet-browser-229d95956bc36ec413533df00389f8c5127e050b.tar.bz2
tangerine-wallet-browser-229d95956bc36ec413533df00389f8c5127e050b.tar.lz
tangerine-wallet-browser-229d95956bc36ec413533df00389f8c5127e050b.tar.xz
tangerine-wallet-browser-229d95956bc36ec413533df00389f8c5127e050b.tar.zst
tangerine-wallet-browser-229d95956bc36ec413533df00389f8c5127e050b.zip
Merge branch 'master' into i#495CustomGasField
Diffstat (limited to 'ui/app/first-time/disclaimer.js')
-rw-r--r--ui/app/first-time/disclaimer.js31
1 files changed, 27 insertions, 4 deletions
diff --git a/ui/app/first-time/disclaimer.js b/ui/app/first-time/disclaimer.js
index c6174a220..819d4a110 100644
--- a/ui/app/first-time/disclaimer.js
+++ b/ui/app/first-time/disclaimer.js
@@ -19,6 +19,9 @@ function DisclaimerScreen () {
}
DisclaimerScreen.prototype.render = function () {
+ const state = this.state || {disclaimerDisabled: true}
+ const disabled = state.disclaimerDisabled
+
return (
h('.flex-column.flex-center.flex-grow', [
@@ -40,18 +43,38 @@ DisclaimerScreen.prototype.render = function () {
.markdown {
font-family: Times New Roman;
+ overflow-x: hidden;
}
.markdown h1, .markdown h2, .markdown h3 {
margin: 10px 0;
- font-family: arial sans-serif;
font-weight: bold;
}
+ .markdown strong {
+ font-weight: bold;
+ }
+ .markdown em {
+ font-style: italic;
+ }
+
+ .markdown p {
+ margin: 10px 0;
+ }
+
+ .markdown a {
+ color: blue;
+ }
+
`),
h('div.markdown', {
+ onScroll: (e) => {
+ var object = e.currentTarget
+ if (object.offsetHeight + object.scrollTop + 100 >= object.scrollHeight) {
+ this.setState({disclaimerDisabled: false})
+ }
+ },
style: {
- // whiteSpace: 'pre-line',
background: 'rgb(235, 235, 235)',
height: '310px',
padding: '6px',
@@ -69,9 +92,9 @@ DisclaimerScreen.prototype.render = function () {
h('button', {
style: { marginTop: '18px' },
+ disabled,
onClick: () => this.props.dispatch(actions.agreeToDisclaimer()),
- }, 'I Agree'),
+ }, disabled ? 'Scroll Down to Enable' : 'I Agree'),
])
)
}
-