Add "escape hatch" when running as web app on app.helena.express

master
Skylar Ittner 3 years ago
parent 9021d13604
commit 30559b1f93

@ -9,6 +9,12 @@
<div class="navbar-inner">
<div class="title">{{js "SETTINGS.branding.apptitle"}}</div>
<div class="right">
{{#if escapehatch}}
<a href="https://helena.express" class="link external">
<i class="fal fa-portal-exit"></i>
<span>Back to Website</span>
</a>
{{/if}}
<a href="/settings" class="link icon-only hapticbtn">
<i class="fal fa-cog"></i>
</a>

@ -30,11 +30,17 @@ var routes = [
async: function (routeTo, routeFrom, resolve, reject) {
// Show a nag message if no account is set up
var accountsetup = (inStorage("accountkey") && inStorage("phonenumber")) || getStorage("hideaccountnag") == "true";
// add escape hatch to regular website if running online
var escapehatch = false;
if (window.location.hostname == "app.helena.express") {
escapehatch = true;
}
resolve({
templateUrl: './pages/home.html'
}, {
context: {
accountsetup: accountsetup,
escapehatch: escapehatch,
pages: [
{
title: "Drop and Send",

Loading…
Cancel
Save