aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorThomas Huang <tmashuang@users.noreply.github.com>2019-08-07 03:50:16 +0800
committerGitHub <noreply@github.com>2019-08-07 03:50:16 +0800
commitf679b58fcd116b5b4c3896e6aa9a16c54c0ab1ee (patch)
treee2da40aeae0a7b5dd01dc276c9a9bb4cacdad871
parent0e51292acf5146b4eaad01e1616a5241fb6aaacc (diff)
parentb3833b1074d7bc1b9836c7f09f8ad04ab100c714 (diff)
downloadtangerine-wallet-browser-f679b58fcd116b5b4c3896e6aa9a16c54c0ab1ee.tar
tangerine-wallet-browser-f679b58fcd116b5b4c3896e6aa9a16c54c0ab1ee.tar.gz
tangerine-wallet-browser-f679b58fcd116b5b4c3896e6aa9a16c54c0ab1ee.tar.bz2
tangerine-wallet-browser-f679b58fcd116b5b4c3896e6aa9a16c54c0ab1ee.tar.lz
tangerine-wallet-browser-f679b58fcd116b5b4c3896e6aa9a16c54c0ab1ee.tar.xz
tangerine-wallet-browser-f679b58fcd116b5b4c3896e6aa9a16c54c0ab1ee.tar.zst
tangerine-wallet-browser-f679b58fcd116b5b4c3896e6aa9a16c54c0ab1ee.zip
Merge pull request #6968 from MetaMask/prevent-hidden-popup-overlay
Prevent hidden popup overlay
-rw-r--r--ui/app/components/app/multiple-notifications/index.scss2
-rw-r--r--ui/app/components/app/multiple-notifications/multiple-notifications.component.js32
2 files changed, 19 insertions, 15 deletions
diff --git a/ui/app/components/app/multiple-notifications/index.scss b/ui/app/components/app/multiple-notifications/index.scss
index e3ee39a74..e8d064bc0 100644
--- a/ui/app/components/app/multiple-notifications/index.scss
+++ b/ui/app/components/app/multiple-notifications/index.scss
@@ -3,7 +3,6 @@
display: flex;
flex-direction: column;
width: 472px;
- height: 116px;
position: absolute;
bottom: 0;
right: 0;
@@ -37,7 +36,6 @@
}
.home-notification-wrapper--show-all {
- height: 356px;;
justify-content: flex-end;
margin-bottom: 0;
diff --git a/ui/app/components/app/multiple-notifications/multiple-notifications.component.js b/ui/app/components/app/multiple-notifications/multiple-notifications.component.js
index 09020c467..040890e18 100644
--- a/ui/app/components/app/multiple-notifications/multiple-notifications.component.js
+++ b/ui/app/components/app/multiple-notifications/multiple-notifications.component.js
@@ -18,21 +18,27 @@ export default class MultipleNotifications extends PureComponent {
const notificationsToBeRendered = notifications.filter(notificationConfig => notificationConfig.shouldBeRendered)
- return (<div
- className={classnames(...classNames, {
- 'home-notification-wrapper--show-all': showAll,
- 'home-notification-wrapper--show-first': !showAll,
- })}
- >
- { notificationsToBeRendered.map(notificationConfig => notificationConfig.component) }
+ if (notificationsToBeRendered.length === 0) {
+ return null
+ }
+
+ return (
<div
- className="home-notification-wrapper__i-container"
- onClick={() => this.setState({ showAll: !showAll })}
+ className={classnames(...classNames, {
+ 'home-notification-wrapper--show-all': showAll,
+ 'home-notification-wrapper--show-first': !showAll,
+ })}
>
- {notificationsToBeRendered.length > 1 ? <i className={classnames('fa fa-sm fa-sort-amount-asc', {
- 'flipped': !showAll,
- })} /> : null}
+ { notificationsToBeRendered.map(notificationConfig => notificationConfig.component) }
+ <div
+ className="home-notification-wrapper__i-container"
+ onClick={() => this.setState({ showAll: !showAll })}
+ >
+ {notificationsToBeRendered.length > 1 ? <i className={classnames('fa fa-sm fa-sort-amount-asc', {
+ 'flipped': !showAll,
+ })} /> : null}
+ </div>
</div>
- </div>)
+ )
}
}