fix(home): remove FB signup, fix app footer outside of user context

This commit is contained in:
Sabe Jones
2021-11-01 13:58:46 -05:00
parent 0d6e34c646
commit e475ebf65c
4 changed files with 9 additions and 35 deletions

View File

@@ -13,7 +13,7 @@ import {
} from '../../../helpers/common.helper'; } from '../../../helpers/common.helper';
describe('shared.ops.purchase', () => { describe('shared.ops.purchase', () => {
const SEASONAL_FOOD = 'Candy_Base'; const SEASONAL_FOOD = moment().isBefore('2021-11-02T20:00-04:00') ? 'Candy_Base' : 'Meat';
let user; let user;
const goldPoints = 40; const goldPoints = 40;
const analytics = { track () {} }; const analytics = { track () {} };

View File

@@ -1,21 +1,5 @@
<template> <template>
<div class="form-wrapper"> <div class="form-wrapper">
<div
v-if="forgotPassword && preOutage"
class="warning-banner d-flex"
>
<div class="warning-box ml-auto my-auto mr-2 d-flex">
<div
class="svg-icon exclamation m-auto"
v-html="icons.exclamation"
>
</div>
</div>
<div class="mr-auto my-auto">
Habitica emails will be temporarily unavailable on <strong>January 11, 2020</strong> from
<strong>1:00 - 7:00 AM EST</strong>.
</div>
</div>
<div id="top-background"> <div id="top-background">
<div class="seamless_stars_varied_opacity_repeat"></div> <div class="seamless_stars_varied_opacity_repeat"></div>
</div> </div>
@@ -35,7 +19,10 @@
></div> ></div>
</div> </div>
</div> </div>
<div class="form-group row text-center"> <div
class="form-group row text-center"
v-if="!registering"
>
<div class="col-12 col-md-12"> <div class="col-12 col-md-12">
<div <div
class="btn btn-secondary social-button" class="btn btn-secondary social-button"
@@ -48,9 +35,7 @@
<div <div
class="text" class="text"
> >
{{ registering {{ $t('loginWithSocial', {social: 'Facebook'}) }}
? $t('signUpWithSocial', {social: 'Facebook'})
: $t('loginWithSocial', {social: 'Facebook'}) }}
</div> </div>
</div> </div>
</div> </div>
@@ -648,7 +633,6 @@
<script> <script>
import axios from 'axios'; import axios from 'axios';
import hello from 'hellojs'; import hello from 'hellojs';
import moment from 'moment';
import debounce from 'lodash/debounce'; import debounce from 'lodash/debounce';
import isEmail from 'validator/lib/isEmail'; import isEmail from 'validator/lib/isEmail';
import { buildAppleAuthUrl } from '../../libs/auth'; import { buildAppleAuthUrl } from '../../libs/auth';
@@ -738,9 +722,6 @@ export default {
|| this.passwordInvalid || this.passwordInvalid
|| this.passwordConfirmInvalid; || this.passwordConfirmInvalid;
}, },
preOutage () {
return moment.utc().isBefore('2020-01-12');
},
}, },
watch: { watch: {
$route: { $route: {

View File

@@ -106,16 +106,6 @@
<span>{{ $t('or') }}</span> <span>{{ $t('or') }}</span>
</div> </div>
<div class="text-center"> <div class="text-center">
<button
class="social-button"
@click="socialAuth('facebook')"
>
<div
class="svg-icon social-icon"
v-html="icons.facebookIcon"
></div>
<span>{{ $t('signUpWithSocial', {social: 'Facebook'}) }}</span>
</button>
<button <button
class="social-button" class="social-button"
@click="socialAuth('google')" @click="socialAuth('google')"

View File

@@ -5,6 +5,9 @@ export default {
...mapState({ user: 'user.data' }), ...mapState({ user: 'user.data' }),
bugReportMailto () { bugReportMailto () {
let subscriptionInfo = 'Not Subscribed'; let subscriptionInfo = 'Not Subscribed';
if (!this.user) {
return 'mailto:admin@habitica.com?subject=Habitica Web Bug Report';
}
if (this.user.purchased.plan.customerId) { if (this.user.purchased.plan.customerId) {
subscriptionInfo = ` subscriptionInfo = `
Subscription: ${this.user.purchased.plan.planId}%0d%0a Subscription: ${this.user.purchased.plan.planId}%0d%0a