aboutsummaryrefslogtreecommitdiffstats
path: root/app/scripts/lib
diff options
context:
space:
mode:
authorAlexander Tseung <alextsg@gmail.com>2018-01-17 10:17:28 +0800
committerAlexander Tseung <alextsg@gmail.com>2018-01-17 10:17:28 +0800
commit81f86cfab6da37f1a87f3243c6a082f8835ab81b (patch)
tree6af56231142544c5983bbe24d74644011596d003 /app/scripts/lib
parentaa76c5c73c5a9f0507ef69d88a43cf3bee5d60c0 (diff)
parent77eb7b2db692cc40bf5f8e36c5e695e8f82c76ec (diff)
downloadtangerine-wallet-browser-81f86cfab6da37f1a87f3243c6a082f8835ab81b.tar
tangerine-wallet-browser-81f86cfab6da37f1a87f3243c6a082f8835ab81b.tar.gz
tangerine-wallet-browser-81f86cfab6da37f1a87f3243c6a082f8835ab81b.tar.bz2
tangerine-wallet-browser-81f86cfab6da37f1a87f3243c6a082f8835ab81b.tar.lz
tangerine-wallet-browser-81f86cfab6da37f1a87f3243c6a082f8835ab81b.tar.xz
tangerine-wallet-browser-81f86cfab6da37f1a87f3243c6a082f8835ab81b.tar.zst
tangerine-wallet-browser-81f86cfab6da37f1a87f3243c6a082f8835ab81b.zip
Merge branch 'uat' into uat-master-011618
Diffstat (limited to 'app/scripts/lib')
-rw-r--r--app/scripts/lib/environment-type.js10
-rw-r--r--app/scripts/lib/is-popup-or-notification.js5
-rw-r--r--app/scripts/lib/notification-manager.js2
3 files changed, 15 insertions, 2 deletions
diff --git a/app/scripts/lib/environment-type.js b/app/scripts/lib/environment-type.js
new file mode 100644
index 000000000..7966926eb
--- /dev/null
+++ b/app/scripts/lib/environment-type.js
@@ -0,0 +1,10 @@
+module.exports = function environmentType () {
+ const url = window.location.href
+ if (url.match(/popup.html$/)) {
+ return 'popup'
+ } else if (url.match(/home.html$/)) {
+ return 'responsive'
+ } else {
+ return 'notification'
+ }
+}
diff --git a/app/scripts/lib/is-popup-or-notification.js b/app/scripts/lib/is-popup-or-notification.js
index 693fa8751..e2999411f 100644
--- a/app/scripts/lib/is-popup-or-notification.js
+++ b/app/scripts/lib/is-popup-or-notification.js
@@ -1,6 +1,9 @@
module.exports = function isPopupOrNotification () {
const url = window.location.href
- if (url.match(/popup.html$/)) {
+ // if (url.match(/popup.html$/) || url.match(/home.html$/)) {
+ // Below regexes needed for feature toggles (e.g. see line ~340 in ui/app/app.js)
+ // Revert below regexes to above commented out regexes before merge to master
+ if (url.match(/popup.html(?:\?.+)*$/) || url.match(/home.html(?:\?.+)*$/)) {
return 'popup'
} else {
return 'notification'
diff --git a/app/scripts/lib/notification-manager.js b/app/scripts/lib/notification-manager.js
index 7846ef7f0..adaf60c65 100644
--- a/app/scripts/lib/notification-manager.js
+++ b/app/scripts/lib/notification-manager.js
@@ -1,5 +1,5 @@
const extension = require('extensionizer')
-const height = 520
+const height = 620
const width = 360